Sei sulla pagina 1di 2

Database Technology Group

Dep. of Computer Science


Institute for System Architecture

3. Exercise - TIS
ER models“

THEORY PART

1. Three-level Database Architecture (ANSI-SPARC)

• Assign the terms: Internal Level, Logical Level, External Level, Physical Data In-
dependency and Logical Data Independency to the diagram below. Higher levels in
the diagram are more abstract.

• Assign the following activities to the three layers of database abstraction.


(a) Creating a pricing overview for books.
(b) Adding a new table for book categories.
(c) Using an index to search for book titles.
(d) Leveraging the sorting of the book titles for faster analysis.
(e) Finding the most successful authors.
(f) Changing the name of a date field in a table.

2. Translating ER to relational schemata


Transform the following ER diagram into a relational schema!

Date ProdNo

1 N N 1
Order consists_of OrderItem has Product Name

OrderNo Position Quantity Price

1
Database Technology Group
Dep. of Computer Science
Institute for System Architecture

3. ER diagram and relational mapping


Given the following described ’miniworld’ of a library:

• A library consists of books and magazines. Every book is edited by a publisher,


can have several authors, and is uniquely identified by its ISBN (International
Standard Book Number). The library owns several copies of one book.
• In contrast, magazines are available only once and they are not lendable. They are
released in individual booklets and are yearly bound to a book - usually together
with a table of contents.
• The books, as well as the articles published in magazines are assigned to sever-
al subjects (e.g. Operating systems, Database systems, Programming languages).
Furthermore there is a catalogue, from which the relevant citations to a keyword
(e.g. ’Query Language’) can be identified.
• For lending a book, a membership card with name and address of the reader is
necessary. The maximum duration for lending is is four weeks.

Design a corresponding Entity Relationship diagram and classify the relations by rela-
tion types (1:1, 1:n, m:n).
Discuss the transformation into a relational schema. Which relationships will be integra-
ted as independent relation, which will be integrated into the relations for participating
entities?

Potrebbero piacerti anche