问题
E diagram which i need to turn into databse. I know my primary keys but do not really understand how to link the different tables together.
So I have operator table with name as primary key. Each operator can operate certain proportion of those trains. e.g operator "a" 30 = 30% of those services and operator b 70% of those services 100 all of them etc... This is the part im stuck with. Do I need another table to link these two tables together ?
for each train i need to store which station it starts from and where its going to terminate (destination) once again do i create new table for this ?
Thank you in advance
回答1:
You can use your Operates box as a representation of your keys table with OperatorID/TrainID to associate operators with trains.
No, for train start and end stationIDs, you don't need another table, just fields in the Train table.
Is this homework? Are these new concepts for you?
来源:https://stackoverflow.com/questions/13500200/creating-relational-database