Foreign Keys

wxdqz

New Member
If I wanted to have 2 tables, one with member information, and the other with the resources a member has submitted, how would I work out a foreign key in the resources table using a form?

Ex.

User signs up, added to database
User wants to add resource, fills out form with information. How would I make a memberID foreign key in the resouces table corresponding to the members id?

Would I use LAST_INSERT_ID()) ?
 
Back
Top