0% found this document useful (0 votes)
105 views4 pages

Generalization

Generalization

Uploaded by

Sk md Abdul bari
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
105 views4 pages

Generalization

Generalization

Uploaded by

Sk md Abdul bari
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

Generalization, Specialization and Aggregation in ER Model


Using the ER model for bigger data creates a lot of complexity while designing a database model, So in order to
minimize the complexity Generalization, Specialization, and Aggregation were introduced in the ER model and these
were used for data abstraction in which an abstraction mechanism is used to hide details of a set of objects. Some of
the terms were added to the Enhanced ER Model, where some new concepts were added. These new concepts are:
 Generalization
 Specialization
 Aggregation
Generalization
Generalization is the process of extracting common properties from a set of entities and creating a generalized entity
from it. It is a bottom-up approach in which two or more entities can be generalized to a higher-level entity if they
have some attributes in common. For Example, STUDENT and FACULTY can be generalized to a higher-level entity
called PERSON as shown in Figure 1. In this case, common attributes like P_NAME, and P_ADD become part of a
higher entity (PERSON), and specialized attributes like S_FEE become part of a specialized entity (STUDENT).
Generalization is also called as ‘ Bottom-up approach”.

Generalization

Specialization
In specialization, an entity is divided into sub-entities based on its characteristics. It is a top-down approach where the
higher-level entity is specialized into two or more lower-level entities. For Example, an EMPLOYEE entity in an
Employee management system can be specialized into DEVELOPER, TESTER, etc. as shown in Figure 2. In this
case, common attributes like E_NAME, E_SAL, etc. become part of a higher entity (EMPLOYEE), and specialized
attributes like TES_TYPE become part of a specialized entity (TESTER).
Specialization is also called as ” Top-Down approach”.

Specialization

Inheritance: It is an important feature of generalization and specialization


 Attribute inheritance: allows lower level entities to inherit the attributes of higher level entities and vice
versa.
 in diagram: Car entity is an inheritance of Vehicle entity ,So Car can acquire attributes
of Vehicle example:car can acquire Model attribute of Vehicle.
 Participation inheritance: In participation inheritance, relationships involving higher level entity set also
inherited by lower level entity and vice versa.
 in diagram: Vehicle entity has an relationship with Cycle entity ,So Cycle entity can acquire attributes of
lower level entities i.e Car and Bus since it is inheritance of Vehicle.

Example of Relation

Aggregation
An ER diagram is not capable of representing the relationship between an entity and a relationship which may be
required in some scenarios. In those cases, a relationship with its corresponding entities is aggregated into a higher-
level entity. Aggregation is an abstraction through which we can represent relationships as higher-level entity sets.
For Example, an Employee working on a project may require some machinery. So, REQUIRE relationship is needed
between the relationship WORKS_FOR and entity MACHINERY. Using aggregation, WORKS_FOR relationship
with its entities EMPLOYEE and PROJECT is aggregated into a single entity and relationship REQUIRE is created
between the aggregated entity and MACHINERY.
Aggregation

Representing Aggregation Via Schema


To represent aggregation, create a schema containing the following things.
 the primary key to the aggregated relationship
 the primary key to the associated entity set
 descriptive attribute, if exists
FAQs on Generalization, Specialization and Aggregation in ER Model
Q.1: What are Generalization, Specialization, and Aggregation in ER Model?
Answer:
Generalization is the higher level of understanding of data from lower levels of data whereas Specialization is the
process of defining one or more entities from present entities and Aggregation is the process of combining two or
more entities.
Q.2: What is the purpose of the Generalization?
Answer:
Generalization is simply gathering the common properties from entities and creating a generalized concept from
those extracted data. Generalization helps in improving the flexibility, and reusability of the database.
Q.3: Why is generalization important in the database?
Answer:
Generalization is important in the database because it helps to gather important information so that it becomes easier
and faster for the user the analysis of data and it also helps in making decisions faster.

You might also like