Relationship Sets¶
One-One¶
A foreign key to either table is stored in the other table
dam(dam_ID, name, river_ID) river(river_ID, name) {either one can work}
Many-One¶
A foreign key to the "one" table is stored in the "many" table
stream(stream_ID, width, river_ID) flows_into(stream_ID, river_ID)
Many-Many¶
A new table is made to store the information of the relationship
river(stream_ID, name) city(city_ID, population) flows_through(river_ID, city_ID)