Database Fundamentals – Assignment 1
Database Fundamentals – Assignment 1
• For each regular (strong) entity type in the ER schema, create a relation that includes all the simple
attributes (includes simple attributes of composite relations)
• Choose one of the key attributes as the primary key .
• If the chosen key is composite, the set of simple attributes that form it will together form the primary key .
Student
Program
Name program_id CreditPoints YearCommenced
Name : Khalid Jaber Al-Salhi ID: 445013760 Database Assignment
Student
GivenNames Surname Student_ID Date_of_Birth YearEnrolled
Program
Name program_id CreditPoints YearCommenced
Name : Khalid Jaber Al-Salhi ID: 445013760 Database Assignment
• For each weak entity type, create a corresponding relation that includes all the simple
attributes.
• Add as a foreign key all of the primary key attribute(s) in the entity corresponding to the owner
entity type
• The primary key is the combination of all the primary key attributes from the owner and the
partial key of the weak entity, if any
Course
Student
GivenNames Surname Student_ID Date_of_Birth YearEnrolled
Program
Name program_id CreditPoints YearCommenced
Course
program_id course_id Name CreditPoints YearCommenced
Name : Khalid Jaber Al-Salhi ID: 445013760 Database Assignment
Student
Program
Name program_id CreditPoints YearCommenced
Course
program_id course_id Name CreditPoints YearCommenced
Name : Khalid Jaber Al-Salhi ID: 445013760 Database Assignment
Student
FK
Program
Name program_id CreditPoints YearCommenced
Program
Name program_id CreditPoints YearCommenced
Course
program_id course_id Name CreditPoints YearCommenced Year Semester
Name : Khalid Jaber Al-Salhi ID: 445013760 Database Assignment
Student
Program
Name program_id CreditPoints YearCommenced
Course
program_id course_id Name CreditPoints YearCommenced Year Semester
Name : Khalid Jaber Al-Salhi ID: 445013760 Database Assignment
Attempts
Student
Program
Name program_id CreditPoints YearCommenced
Course
program_id course_id Name CreditPoints YearCommenced Year Semester
Attempts
Student
Program
Name program_id CreditPoints YearCommenced
Course
program_id course_id Name CreditPoints YearCommenced Year Semester
Attempts
Final Mapping
Student
Program
Name program_id CreditPoints YearCommenced
Course
program_id course_id Name CreditPoints YearCommenced Year Semester
Attempts