Introduction to Databases Fall-Winter 2009/10
Exercises Michail Kazimianec
Werner Nutt
Damiano Somenzi
1. Conceptual Modeling
(Sample Solutions)
2. Music Database
Below is an ER diagram that captures the data requirements for the music database
as formulated in the exercise sheet. (Note that the requirements make a number of
restrictive assumptions and are not necessarily realistic.)
title
diskID year
Disk
Records
trackNo Song title
authorship Authors Performs instrument
Person
personID nationality
name
Notation: We have replaced double lines with bold lines. For instance, double lines
indicate mandatory participation, double lined boxes indicate weak entities, and double
lined boxes indicate supporting relationships.
1
Explanation: A song is modeled as a weak entity that is owned by the disk on which
it is recorded because it exists only because of that disk.
Both songs and discs have total participation in the relationship “Records” because
on every disc some song is recorded and every song is recorded on some disk.
Also, songs have total participation in both, “Authors” and “Performs” because we
assume that every song has an author is performed by somebody. These two assump-
tions, however, are debatable:
– a song may be a popular tune, the author of which is unknown;
– a song may have been recorded under circumstances where it was impossible to
identify the performing artist.
Whether these constraints are reasonable or not can only be determined if more infor-
mation about the intended application is available.
Person has no complete participation in “Authors” or “Performs”:
– some person may be an author without performing a song;
– another person may perform a song without having authored any.