E-R and EER Models: Relationship Sets

  1. Relationship : A relationship is the association among several It connects different entities through a  meaningful relation.
  2. Relationship Set : A relationship set  is  a set  of relationships  of the  same type.

Consider an example, employees work in different departments. Then relationship exists between employees and departments because each employee must belongs to some department. Relation of all employees with department when combined makes the relationship set because each employee  has  same  kind  of  relation  with  departments.

Here, Employee and Department are two entity sets. r stands for relationship between Employee and Department. Works_in is the relationship set as shown in Figure 2.3.

  • Descriptive Attributes : Attributes of any relationship set are known as descriptive attributes.

1. Degree of Relationship Sets

Total number of entity sets participate in a relationship set is known as degree of that relationship set.

1.1. Binary Relationship Set

A relationship set in which only two entity sets are involved is known as binary relationship set.

Ex. The Figure 2.3 shows the Binary relationship set.

1.2. Ternary Relationship Set

A relationship set in which three entity sets are involved is known as ternary relationship set or  a  relationship  set having  degree  three.

Ex. The Figure 2.4 shows the relationship set works_in, which is a ternary relationship set.

2. Role and Recursive Relationship Set

  • Role : The function of any entity which it plays in relationship set is called that entity’s e.g., employee plays the role of worker in his department in Figure 2.4.
  • Recursive Relationship Set : When the same entity sets participate in same relationship set more than once with different roles each time, then this type of recursive relationship set is known as Recursive Relationship e.g., consider an example of relationship set works_in and two entity set student and college. A student who attends weekend classes in college as student may also be lecturer in that college. Then this person plays two roles (student, faculty)  in  same relationship  set  work_in.

Source: Gupta Satinder Bal, Mittal Aditya (2017), Introduction to Database Management System, 2nd Edition-University Science Press (2017)

Leave a Reply

Your email address will not be published. Required fields are marked *