If I have a subroutine that needs to add a row to each of two related tables, where the auto_increment primary key of one is used as a foreign key in the other, what's the best way to make sure that the same value is added for both fields? Currently I'm inserting NULL for the pk value in the first table, because I have no way (that I know of) of determining what should be the next auto_increment value.
Any thoughts? Thanks in advance.
Fractured Atlas :: Liberate the Artist
Services: Healthcare, Fiscal Sponsorship, Marketing, Education, The Emerging Artists Fund
Any thoughts? Thanks in advance.
Fractured Atlas :: Liberate the Artist
Services: Healthcare, Fiscal Sponsorship, Marketing, Education, The Emerging Artists Fund