5 Replies Latest reply on Jan 3, 2010 10:17 AM by comment_1

    auto entry serial number as client id

    nh

      Title

      auto entry serial number as client id

      Post

      Newbie. FileMaker Pro 10 trial.  Windows XP Home.

       

      I must be missing something very obvious and feel dumb.  Spent two days looking for answer to no avail.  Please Help!

       

      I have two tables, Client Contact Data and Demographic Data.  I want to establish a relationship between these tables using a match field named Client ID which is an auto entry serial number in the Client ID field of the Client Contact Data table.  Can you please tell me how to get the Client ID field in the Client Contact Data table into the Client ID field in the Demographic Data table as a match so I can set up a relationship between these tables using Client ID as the matching field?

       

      Thank you, nh.

        • 1. Re: auto entry serial number as client id
          bcooney
            

          You need a foreign ClientID field in the Demographic Table. I use the nomenclature _kF_ClientID for a foreign key and __kP_ClientID for a primary key. So, create a number field in Demographic, _kF_ClientID.

           

          There is no automatic way to relate the two tables. You need to manually populate the child record with the correct ClientID, since you aren't creating child records, but rather updating existing records.

           

          One way to make the job of populating the foreign key easier is to create a value list of ClientIDs and names. Then attach this value list to the foreign key _kF_ClientID and format the field to be a popup menu.

            

          • 2. Re: auto entry serial number as client id
            comment_1
              

            nh wrote:

            Can you please tell me how to get the Client ID field in the Client Contact Data table into the Client ID field in the Demographic Data table as a match


            Do they currently have any field/s with matching values?


            • 3. Re: auto entry serial number as client id
              nh
                

              bcooney.  Thank you very much for your help.

               

              nh.

              • 4. Re: auto entry serial number as client id
                nh
                  

                Super Contributor:

                 

                Thank you for the reply.  I do have 3 matching fields in both tables, First Name, Last Name, Birthdate.

                 

                nh. 

                • 5. Re: auto entry serial number as client id
                  comment_1
                    

                  Well, then you can - temporarily - set the relationship to use these three fields as matchfields.

                   

                  Next, go to a layout of the Demographics table and replace the contents of the local ClientID field with the value from the related ClientID in Clients.

                   

                  Finally, switch the relationship back to using ClientID as the match.