Enhanced Entity-Relationship Modeling - PowerPoint PPT Presentation

About This Presentation
Title:

Enhanced Entity-Relationship Modeling

Description:

Enhanced Entity-Relationship Model ... To add descriptive attributes specific to a subclass ... Used when we have to model a relationship involving a relationship type ... – PowerPoint PPT presentation

Number of Views:51
Avg rating:3.0/5.0
Slides: 18
Provided by: thomas854
Category:

less

Transcript and Presenter's Notes

Title: Enhanced Entity-Relationship Modeling


1
Chapter 12
  • Enhanced Entity-Relationship Modeling

2
Enhanced Entity-Relationship Model
  • Basic concepts of ER modeling are not sufficient
    to represent requirements of newer, more complex
    applications.
  • Semantic concepts are incorporated into the
    original ER model and called the Enhanced
    Entity-Relationship (EER) model.
  • Examples of additional concepts of EER model are
  • specialization / generalization
  • aggregation

3
Specialization / Generalization
  • Superclass
  • An entity type that includes one or more distinct
    subgroupings of its occurrences.
  • Subclass
  • A distinct subgrouping of occurrences of an
    entity type.

4
Specialization / Generalization
  • Superclass/subclass relationship is one-to-one
    (11).
  • Superclass may contain overlapping or distinct
    subclasses.
  • Not all members of a superclass need be a member
    of a subclass.

5
Specialization / Generalization
  • Attribute Inheritance
  • An entity in a subclass may possess
    subclass-specific attributes, as well as those
    associated with the superclass.
  • Specialization Process of maximizing differences
    between members of an entity by identifying their
    distinguishing characteristics.
  • Generalization Process of minimizing differences
    between entities by identifying their common
    characteristics. .

6
AllStaff relation holding details of all staff
7
Specialization/generalization of Staff entity
into subclasses representing job roles
8
Specialization/generalization of Staff entity
into job roles and contracts of employment
9
EER diagram with shared subclass and subclass
with its own subclass
10
Constraints on Specialization / Generalization
  • Two constraints that may apply to a
    specialization/generalization
  • participation and disjoint constraints
  • Participation constraint Determines whether
    every member in superclass must participate as a
    member of a subclass.
  • May be mandatory or optional.
  • Disjoint constraint Describes whether member of
    a superclass can be a member of one, or more than
    one, subclass.
  • May be disjoint (Or) or nondisjoint (And).

11
Constraints on Specialization / Generalization
  • There are four categories of constraints of
    specialization and generalization
  • mandatory and disjoint
  • optional and disjoint
  • mandatory and nondisjoint
  • optional and nondisjoint.
  • Reasons for using Specialization/Generalization
  • To add descriptive attributes specific to a
    subclass
  • To identify entities that participate in a
    relationship

12
DreamHome worked example - Staff Superclass with
Supervisor and Manager subclasses
13
DreamHome worked example - Owner Superclass with
PrivateOwner and BusinessOwner subclasses
14
EER diagram of Branch view of DreamHome with
specialization/generalization
15
Aggregation (textbook uses a different concept)
  • Different meaning in UML (has-a or is-part-of
    relationships in UML)
  • Used when we have to model a relationship
    involving a relationship type
  • Aggregation allows us to treat a relationship
    type as a high level entity for purpose of
    participation in other relationships.

16
Example of Aggregation
Contact_Name Contact_Phone Date
Job_Applicant SSN Name Address Phone
Company Cname Caddress
1
11
Interview
11
Starting_Date Starting_Salary
Results_in
01
Job_Offer Position
17
Example of incorrect design
Job_Applicant SSN Name Address Phone
Company Cname Caddress
11
11
Contact_Name Contact_Phone Date Starting_Date Star
ting_Salary
If an interview does not result in an offer, then
Starting_Date and Starting_Salary are
NULL. Multiplicities are different than those on
previous diagram. May show a wrong interview
instance that is not allowed by the aggregation.
01
Job_Offer Position
Write a Comment
User Comments (0)
About PowerShow.com