Lab Session 2
Lab Session 2
ER Diagram – ER diagram stands for Entity Relationship Diagram, also known as ERD is a diagram
that displays the relationship of entity sets stored in a database. In other words, ER diagrams help to
explain the logical structure of databases. ER diagrams are created based on three basic concepts: entities,
attributes and relationships..
ER Diagrams contain different symbols that use rectangles to represent entities, ovals to define attributes
and diamond shapes to represent relationships.
Table for Entity sets and Attributes for Library Management System
Pin_code District
Return_date
Post Address
Due_date Issue.
_
1 Age
Subject Book_name Written
by
Manage
M Books 1
Price
Edition Author_name.
1
Issue
Name
M M Fine
Pays
Stu_Id 1
Student Payment_date Fine_amount
.
Reg_no Contact_no
Roll_no
Address
_ District
Post
Pin_code
OBJECT- To create an ER Diagram for Hospital Management System.
Table for Entity sets and Attributes for Hospital Management System
Dr_Id
Dr_name
Pin_code
District Mobile
Doctors
Age
Address Post Specialization
sss
Name
Pat_Id has
Qualification
Patient
Hospital
Admit
in
has has
Medicine_name
Medicines
Details
Type Medicine_Id
Report
Medical records
Payment
Record_Id
Problem Date_of__exam
_Id ine