What is an Entity relationship model in DBMS?

DBMSDatabaseBig Data Analytics

Entity relationship (ER) models are based on the real-world entities and their relationships. It is easy for the developers to understand the system by simply looking at the ER diagram. ER models are normally represented by ER-diagrams.

Components

ER diagram basically having three components:

  • Entities − It is a real-world thing which can be a person, place, or even a concept. For Example: Department, Admin, Courses, Teachers, Students, Building, etc are some of the entities of a School Management System.

  • Attributes − An entity which contains a real-world property called an attribute. For Example: The entity employee has the property like employee id, salary, age, etc.

  • Relationship − Relationship tells how two attributes are related. For Example: Employee works for a department.

An entity has a real-world property called attribute and these attributes are defined by a set of values called domain.

Example 1

In a university,

  • A student is an entity,

  • University is the database,

  • Name and age and sex are the attributes.

  • The relationships among entities define the logical association between entities.

Example 2

Given below is another example of ER:

In the above example,

Entities − Employee and Department.

Attributes −

  • Employee − Name, id, Age, Salary

  • Department − Dept_id, Dept_name

The two entities are connected using the relationship. Here, each employee works for a department.

Features of ER

The features of ER Model are as follows −

  • Graphical Representation is Better Understanding − It is easy and simple to understand so it can be used by the developers to communicate with the stakeholders.

  • ER Diagram − ER diagrams are used as a visual tool for representing the model.

  • Database Design − This model helps the database designers to build the database.

Advantages

The advantages of ER are as follows −

  • The ER model is easy to build.

  • This model is widely used by database designers for communicating their ideas.

  • This model can easily convert to any other model like network model, hierarchical model etc.

  • It is integrated with the dominant relational model.

Disadvantages

The disadvantages of ER are as follows −

  • There is no industry standard for developing an ER model.

  • Information might be lost or hidden in the ER model.

  • There is no Data Manipulation Language (DML).

  • There is limited relationship representation.

raja
Published on 03-Jul-2021 09:46:24
Advertisements