assignment 6-1 schedule(staffno, dentistname, patno, patname, surgeryno, date, time) make...
TRANSCRIPT
Assignment 6-1Schedule(staffNo, dentistName, patNo, patName, surgeryNo, Date, Time)
Make assumptions:• surgeryNo is the surgery room number.
• staffNo, patNo, and surgeryNo are unique.
• A patient is allowed to have more than one surgery a day.
• Only one surgery can take place in a room at any given time.
• A dentist can perform only one surgery at any given time.
• A dentist is allocated in one surgery room each day.
• But a surgery room can be used by multiple dentists on the same day.
• Date and Time as two separate attributes. Do NOT use Appointment!
1
Assignment 6-1surgeryNo, Date ===> staffNoWhat does it mean?A surgery room is reserved for one dentist a day.-0.5
staffNo, Date ===> surgeryNo What does it mean?A dentist is allocated to a specific surgery room for each day.Yes!
staffNo surgeryNo Date Time …
S1011 S15 12-Sep-04 10:00
S1011 S15 12-Sep-04 12:00
S1024 S15 12-Sep-04 14:00
S1011 S14 13-Sep-04 10:00 2
Assignment 6-1
patNo, Date ===> ALLWhat does it mean?A patient can have at most one surgery a day.Usually is true.Not a rule we want to make.
-0.5
3
Assignment 6-1
patNo, staffNo ===> ALLWhat does it mean?A patient can see one dentist once, and hence
must see a different dentist each time visiting the clinic.
-0.5
4
Assignment 6-1
Candidate keys: staffNo, Date, Time surgeryNo, Date, Time patNo, Date, Time
Must have FDs:staffNo, Date, Time ===> AllsurgeryNo, Date, Time ===> AllpatNo, Date, Time ===> All
5
Assignment 6-11.staffNo dentistNamepatNo patName staffNo, Date, Time AllpatNo, Date, Time AllsurgeryNo, Date, Time AllstaffNo, Date surgeryNo
2.staffNo, Date, Time(any one of the three ALL FDs)
3.patNo, Date, TimesurgeryNo, Date, Time
6
Quiz2
Change UserName to your UWP UserName first!
7