Results 1 to 4 of 4
Thread: Inner-Join vs Foreign Key
Jan 4, 2005, 12:19 #1
Inner-Join vs Foreign Key
OK so i'll throw my hands up and admit- i'm somewhat a newbie in the practicalities of mysql (relationships and normal form, on the other hand, are no probs).
I've been trying to design a database where a property table holds an entry for a property that is for sale and there is one field "user-id" that I want to link to the user table so that when they select the property from the list of displayed properties I can query both tables in order to get info regarding the seller and the property.
It's a 1:many relationship (user: property) and I was wondering this...
I was going to have the "user-id" in the property table as a FK relating to the "user" table. However I've also seen that "..JOIN" statements exist and I was wondering which is the best method to use? If I use the FK do i still need to create the query with a 'join' syntax?