Results 1 to 6 of 6
  1. #1
    Huddle is offline Competent Performer
    Windows XP Access 2010 64bit
    Join Date
    Jun 2010
    Posts
    318

    Gathering Data from Two Tables to a Connecting Table

    I have two tables: "Tbl_CM_Project_Details" and "Tbl_CM_Inventory" that have the data that I am trying to connect with a third table: Tbl_CM_Proj_CMI_Connector.

    Tbl_CM_Project_Details connecting field is PK_Project_Num to Tbl_CM_Proj_CMI_Connector field Connecting_Project_Num
    Tbl_CM_Inventory connecting field is CMI_ID to Tbl_CM_Proj_CMI_Connector field Connecting_CMI_ID

    On the form I have a SQL Query where I enter the PK_Project_Num and the CMI_ID Auto enters. What I need is for this information to automatically fill the connecting table so that the information is connected.

    Any suggestions on how to accomplish this?

  2. #2
    orange's Avatar
    orange is online now Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,742
    Can you tell us in plain English what you are trying to accomplish?
    Do you have a many to many relationship between "Tbl_CM_Project_Details" and "Tbl_CM_Inventory"?

  3. #3
    Huddle is offline Competent Performer
    Windows XP Access 2010 64bit
    Join Date
    Jun 2010
    Posts
    318
    I need PK_Project_Num to automatically fill Connecting _Project_Num when I enter PK_Project_Num into the form. And I need CMI_ID to automatically fill Connecting_CMI_ID when I the CMI_ID auto enters so that the data between the two table can be connected by the third without me having to go into the third table and enter the information.
    Attached Thumbnails Attached Thumbnails sample2.jpg  

  4. #4
    orange's Avatar
    orange is online now Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,742
    How do you think Access or any software would know these values?

    Consider an analagous situation with Students and Courses

    Student<---->Course (many to many)

    To resolve the situation

    Student--->StudentEnrolledInCourse<---Course

    tblStudent
    StudentId PK
    StudentName
    other Student info

    tblCourse
    CourseId
    CourseName
    CourseDsecription
    other course info


    tblStudentEnrolledInCourse
    StudentEnrolledInCourseId PK

    StudentId (these make up a unique compound index(to prevent duplicates)
    CourseId

    other fields specific to this combination such as Grade

  5. #5
    Huddle is offline Competent Performer
    Windows XP Access 2010 64bit
    Join Date
    Jun 2010
    Posts
    318
    I thought there might be a way that when I entered PK_Project_Num on the form Connecting_Project_Num could be auto filled on the form using some type of ME. statement. Or that the Connecting_CMI_ID could default to the CMI_ID. There is usually more than one way to skin a cat but if it's not doable I can accept that.

  6. #6
    orange's Avatar
    orange is online now Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,742
    I don't think there is any method to do what you are asking. If you look at the Students/Courses analogy, you(user) have to assign a Student to a Course.

    There is a video here that goes through this common process
    https://www.youtube.com/watch?v=7XstSSyG8fw

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Gathering Online Registration Data
    By EHittner in forum Misc
    Replies: 1
    Last Post: 07-05-2012, 02:22 AM
  2. Gathering data via Outlook using existing VBA code
    By Monterey_Manzer in forum Programming
    Replies: 1
    Last Post: 07-03-2012, 06:29 PM
  3. Connecting periods from different tables - database design problem
    By sockswithsandals in forum Database Design
    Replies: 4
    Last Post: 04-15-2012, 08:39 AM
  4. connecting two tables?
    By imintrouble in forum Access
    Replies: 1
    Last Post: 01-24-2012, 02:22 PM
  5. Database design - connecting 2 tables
    By Eisaz in forum Database Design
    Replies: 2
    Last Post: 10-16-2009, 09:19 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums