Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2013

    Unanswered: Please explain something about foreign keys

    Hi, thanks in advance for any help.

    I have a question about foreign keys. I understand the concept of having the data from one table inserted into another for reference. But my question is, how does it get there?

    Currently I have two tables and two forms. One form inserts data into table A, the other form inserts into B. Then I use a function to get the id from the last insert into A and insert it into B. Is this the proper way to do this or am I missing something?

  2. #2
    Join Date
    Sep 2009
    San Sebastian, Spain
    This is the correct way of doing this.
    Ronan Cashell
    Certified Oracle DBA/Certified MySQL Expert (DBA & Cluster DBA)
    Follow me on Twitter

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