Music Database: Salary:money)
Music Database: Salary:money)
Music Database: Salary:money)
Music Database
A database needs to be developed that keeps track of compact disks, and songs recorded
on them, together with authors and performers of the songs. The data requirements are
as follows:
1. For each disk, we want to store the disk ID, the title, and the year of production.
Disk ID’s are unique.
2. A song is recorded on some disk. It has a title and a number that indicates on
which track it is recorded on the disk. For each disk, a song is uniquely identified
by its track number.
3. For each person that may occur as a an author or a performer we want to store
the person ID, the name, and the nationality. Person ID’s are unique.
4. Each song has at least one author who is a person. There are different types of
authorship, e.g., composer, text writer, or arranger. For each author of a song,
we want to store the type of authorship.
5. Each song has at least one performer who is a person. There are different instruments for a
performer, e.g., voice, piano, violin. We want to store for each
performer the instrument they have played during the recording.
Ex2 (5 point):
Giving a database schema:
- Employee(emp_id: integer, firstname: string, lastname: string, deparment_id: int, gender:string,
salary:money)
- Department(dept_id:integer , dept_name: string)
Employee