Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

foreign key from different tables

FidelieFidelie Member Posts: 32
Helo,
I have a table participants and a table projects .
The Primary Keys are:
participants: participant_id
projects: project_id

Between those 2 tables there s a many -many relation.
Therefor I have created a third table called assignment which has in it the columns participant_id and project_id.
This table should have as its key participant_id and project_id which are referring to the columns with same name in the 2 other tables.
I wonder how to write this in MySQL.
I tried many things but no of them worked ..
Thank You much
/Fidelie

Sign In or Register to comment.