A Micro Project On
A Micro Project On
An ER diagram displays the relationship among entity sets. An entity set is a group of
identical entities and these entities can have attributes. In terms of DBMS, an entity is a
table or attribute of a table in the database, so by showing the relationship among tables
and their attributes, ER diagram illustrates the complete logical structure of a database.
Let's have a look at a simple ER diagram to comprehend this concept.
A simple ER Diagram:
In the following diagram, we have two entities Student and College, and their
relationship. The relationship between Student and College is many to one as a college
can have numerous students however a student cannot study in numerous colleges at
the same time. Student entity has attributes such as Stu_Id, Stu_Name & Stu_Addr and
College entity has attributes such as Col_ID .
Here are the geometric shapes and their significance in an E-R Diagram.
Elements of an ER Diagram
Weak Entity:
An entity that cannot be uniquely determined by its own attributes and relies on the
relationship with another entity is called a weak entity. The weak entity is defined by a
double rectangle. For example – a bank account cannot be uniquely determined without
knowing the bank to which the account belongs, so bank account is a weak entity.
2. Attribute