Chap 4
Chap 4
Chap 4
a) EER
notation
b) Microsoft Visio
Notation
Different modeling tools may have different notation for the same
modeling constructs.
1. What are the common attributes for all these types of vehicles ?
2. What is the supertype/subtype relationship ?
So we put
the shared
attributes in
a supertype
Note
No subtype for motorcycle, since it has no unique attributes
The only attributes of MOTOTCYCLE are those common to all vehicles
Chapter 3 © 2013 Pearson Education
13
Figure 3-5 Example of specialization process
a) Entity type PART
Only applies to
manufactured parts
Created 2
subtypes
PATIENT
RESIDENCE
OUTPATIENT PATIENT
PART
M PART P PART
PART
When does this situation happen ?
M PART P PART
Chapter 3 © 2013 Pearson Education
21
CONSTRAINTS IN
SUPERTYPE/SUBTYPE RELATIONSHIPS
Subtype Discriminator
An attribute of the supertype whose values determine
the target subtype(s)
For disjoint subtypes
1. Three cases:
• Y, Y
• Y, N
• N, Y
2. Why 3
cases?
Case 2 Case 3
26
Example of supertype/subtype hierarchy
27
ENTITY CLUSTERS
EER diagrams are difficult to read when
there are too many entities and
relationships.
Solution:
Group entities and relationships into entity clusters.
Entity cluster
A set of one or more entity types and associated relationships
grouped into a single abstract (virtual) entity type
Related groups
of entities could
become entity
clusters
More readable,
isn’t it?
32