Representing IS-A Relationship in DBMS:
Representing subtypes IS-A relationship is
different than binary and unary relationship. Different strategies are used to
represent IS-A relationship. Usually, the following strategy is followed.
- Create a separate relation for supertype and
for each of the subtype.
- Place each of the attributes of the
supertype into the relation that represent it and each of the attributes of
the subtypes into the relations that represent them.
- Add the key of the supertype, to each of the
subtypes to create keys for them. It means that each subtype has the same
key as supertype. The keys of the supertype and each of the subtype have the
It is possible for one or more of the subtypes to
have a key of its own. It is also noted that, the relationship between supertype
and one of the subtype is 1:1.
For example, an IS-A relationship is shown below,
In this figure, there are three entities such as EMPLOYEE, FULL-TIME and
VISITING. The entities FULL-TIME and VISITING represent the subtypes of EMPLOYEE
and have the same primary key as EMPLOYEE.
So the corresponding relations are:
EMPLOYEE (Emp-ID, Name, Address)
FULL-TIME (Emp-ID, DOJ, BPS)
VISITING (Emp-ID, Hours, Rat-e-per-hour)
Representing Binary Relationship
Representing Unary Relationship
Representing Ternary Relationship