Results 1 to 2 of 2
  1. #1
    McArthurGDM is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jul 2014
    Posts
    215

    Master & Subforms Add New Records Dilemma

    Hi,



    This is a follow-up from a previous post that you can delete because I've managed to simplify my question a little better.

    I have two Tables, Table A and Table B

    Table A and B have a one to many relationship with A (one) and B (many).

    I have a Master form that displays information for Table A. Also, I have a subform within this Master that displays information for Table B.

    As I scroll through the records of A, you can see the 1-many relationship elucidated in the subform with many being displayed for Table B.

    I run into a dilemma, though, when I try to ADD a new record to Table A (and in turn Table B).

    ---

    When I add a new record, there is no Primary Key left to be displayed since this primary key is generated from a query.

    Hence, when I move to a new record, I can not save the record because there is no primary key. Since there is no primary key, there is nothing that i can input into the subform either.

    I want to create the primary key from values entered in the field. However, i CAN NOT create a relationship with an expression for field values.

    I can not get around this issue and it's irritating me to no end.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,970
    What do you mean the primary key is generated form a query? How would that be?

    If you want to provide db for analysis, follow instructions at bottom of my post.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. Master/Child Link between Forms/Subforms
    By Stephanie53 in forum Forms
    Replies: 2
    Last Post: 04-02-2013, 08:14 PM
  2. Replies: 57
    Last Post: 04-02-2013, 12:01 PM
  3. Linking Subforms on Unbound Master Form?
    By 10 Gauge in forum Forms
    Replies: 8
    Last Post: 07-21-2011, 08:06 AM
  4. Replies: 22
    Last Post: 03-15-2011, 07:17 AM
  5. Master/Child between Subforms
    By Pilotwings_64 in forum Forms
    Replies: 3
    Last Post: 08-22-2010, 01:45 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