Enhanced ERD (EERD)

Enhanced ERD (EERD)

Extended Entity Relationship Model (EERM)

EER is a high-level data model that extends the original ER model.

EER diagram (EERD) uses the EER model.

Feature of EERD

  • EER makes database schemas more accurate.
  • It reflects data properties and constraints more precisely.
  • It is an extension of ER model, so it includes all modelling concepts of ER model.
  • Diagrammatic technique helps for displaying the EER schema.
  • It is used to represent a collection of objects, which is a union of objects of different entity types.

Subtypes and Supertypes

A supertype is a generalization of one or more subtypes, while a subtype is a specialization of a supertype.

Their relation is similar to class and object in OOP programming.

Entity Supertypes and Subtypes

  • Entity supertype: Generic entity type related to one or more entity subtypes.
  • Entity subtype: Contains unique characteristics of each entity subtype.

Subtype Discriminator

It is attributes in the supertype entity that determines to which entity subtype the supertype occurrence is related.

The default comparison condition is the equality comparison.

Subtypes discriminator is like if statement in programming languages.

Inheritance

Inheritance allows subtypes to inherit attributes and relationships from their supertype.

EER model allows attributes to be inherited from a superclass to its subclasses, meaning that attributes defined in the superclass are automatically inherited by all its subclasses.

Disjoint and Overlapping Constraints

  • Disjoint subtypes: Contain a unique subset of the supertype entity set. They are known as non-overlapping subtypes, and the implementation is based on the value of the subtype discriminator attribute in the supertype.
  • Overlapping subtypes: Contain non-unique subsets of the supertype entity set. The implementation requires the use of one discriminator attribute for each subtype.

Example:

Example

Completeness Constraint

It specifies whether each supertype occurrence must also be a member of at least one subtype.

It has two types:

  • Partial completeness: Not every supertype occurrence is a member of a subtype.
  • Total completeness: Every supertype occurrence must be a member of any subtype.

Specialization and Generalization

Specialization Generalization
Top-down process Bottom-up process
Identifies lower-level entity subtypes from a higher-level entity supertype Identifies a higher-level entity supertype from lower-level entity subtypes
Based on grouping unique characteristics and relationships of the subtypes Based on grouping common characteristics and relationships of the subtypes
Last updated on