Results 1 to 2 of 2
  1. #1
    burrina's Avatar
    burrina is offline VIP
    Windows 7 64bit Access 2010 64bit
    Join Date
    Oct 2012
    Location
    Freeport,Texas
    Posts
    1,383

    Join Key Error Using Form

    Error Message is; The current field must match the join key in the table that serves as the one side of the one to many relationship.
    Enter a record in the one side table with the desired key value, and then make the entry with the desired join key in the many only table.

    Form CompanyOrderSubform
    Query CompanyDetailsExtended


    Tables Used CompanyDetails
    Products

    Linked By ProductID on a one to one in the Query
    Relationship Linked By ProductID as One To Many With Enforcements
    Attached Thumbnails Attached Thumbnails Relationships.jpg   Join Key Error.jpg   Edit Relationships.jpg  

  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,870
    Forms and subforms usually display records from tables that are in a 1 to many relationship.

    a)On the 1 side of the relationship you could have Student, and on the Many side Courses.
    b)Or 1 side Person and many side Hobbies
    c)or 1 side Order and on the many side OrderItems

    When you set these up to use Form subform, you will get a prompt to LinkMasterFields and ChildFields

    So using the examples above, the fields to Link the MainForm and the subform would be
    a)StudentId
    b) PersonId
    c)OrderId
    I'm attaching a sample from Northwind Database Order Form and OrderDetails subform

    There is a free video tutorial on this at
    https://www.youtube.com/watch?v=YZKN_-P6wck
    Attached Thumbnails Attached Thumbnails LinkMasterAndChildFields.jpg  

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

Similar Threads

  1. Replies: 1
    Last Post: 02-19-2012, 07:21 PM
  2. Join Error
    By snowboarder234 in forum Database Design
    Replies: 11
    Last Post: 09-19-2011, 09:03 PM
  3. Replies: 8
    Last Post: 05-12-2011, 06:11 PM
  4. Ambiguous Outer Join Error
    By scruiks in forum Queries
    Replies: 3
    Last Post: 07-18-2010, 05:06 PM
  5. Error on Multiple Table Join & IIF
    By cmartin in forum Queries
    Replies: 1
    Last Post: 05-21-2010, 08:58 PM

Tags for this Thread

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