OK this is probably very basic for the majority of you, but I'm struggling to do this assignment (Yep, it's homework). I've attempted this twice now and failed both times so far.
I need to create a relational data model in Boyce Codd Normal Form. Here are the details:
The Airport Authority in a small nation requires a database to store information about airlines, pilots and planes.
There is only one airport but several airlines use it. For each airline its identification code and full name is required together with the phone number of its local office. Several types of plane use the airport and for each type, the fuel capacity and maximum range is to be recorded.
Each pilot works for only one airline. For each pilot, their name, date of birth, address, the types of plane they can fly and their pilot‟s licence number is to be recorded. Further information is to be recorded to enable the production of a report listing the following details for each plane that uses the airport: Plane identification code, Plane type, Date of manufacture, Owning airline.
This is what I now have (After re-designing):
The table AIRLINES should include:
ID,
Name,
Phone #
The table PLANES should include:
ID,
Date of Manufacture
Airline ID
FOREIGN KEY (Airline ID) references table AIRLINES
Plane Type ID
FOREIGN KEY (Plane Type ID) references table PLANE TYPE
The table PLANE TYPE should include:
ID,
Maximum range,
Fuel capacity,
The table PILOTS should include:
ID,
Name,
Date of Birth,
Address,
License #,
Airline ID,
FOREIGN KEY (Airline ID) references table AIRLINES
PilotPlaneID
FOREIGN KEY (PilotPlaneID) references table PILOTPLANETYPE
The table PILOTPLANETYPE should include:
PilotID
PlaneTypeID
FOREIGN KEY (PilotID) references table PILOT
FOREIGN KEY (PlaneTypeID) references table PLANE TYPE
According to my marker, I had have left a many to many relationship between Pilot and Plane Type. Can someone with some database design knowledge please give me helping hand?
(EDIT: Tables now updated with PILOTPLANETYPE, which I think should satisfy the requirements)?