DBMS Slide 9 Conversion of ER To Relational PPT
DBMS Slide 9 Conversion of ER To Relational PPT
DBMS Slide 9 Conversion of ER To Relational PPT
MANAGEMENT
SYSTEMS
Conversion of ER model
to Relational Model
The notations may be used to represent the database, and these notations
can be condensed into a set of tables.
Conversion of ER to Relational
• All single-valued attribute becomes a column for the table.
l_no
amount
Conversion of ER to Relational
LOAN
l_no …………...
payment_no
amount amount
Conversion of ER to Relational
Loan_
LOAN payment PAYMENT
date
LOAN =(l_no, amount)
PAYMENT =(loan_no, payment_no, payment_date, payment_amt)
The main key of the connection is formed by joining the primary key
characteristics from the participating entity sets.
Conversion of ER to Relational
pin CUSTOMER
Student borrower LOAN
c_name t_date
Conversion of ER to Relational
pin CUSTOMER
Student borrower LOAN
c_name t_date
Conversion of ER to Relational
pin EMPLOYEE borrower DEPARTMENT
ename
add
eid
hod
EMPLOYEE manages
teacher
Conversion of ER to Relational
Employee = (eid, ename, address)
Manages= (hodid, teacherid)
F_name
id STUDENT
name M_name
Conversion of ER to Relational
Student = (id, f_name, m_name, l_name) L_name
id STUDENT mobile
name add
Conversion of ER to Relational
Student = (id, name, add)
Student_mobile = (id, mobile)
7. Representation of Generalization/Specialization
name street
Pid
city
PERSON
Conversion of ER to Relational
Is
A
salary EMPLOYEE
CUSTOMER ratings
7. Representation of Generalization/Specialization
Conversion of ER to Relational
Customer = (customer_id, name, address, credit_rating)
8. Representation of Aggregation
Create a schema with the primary key of the aggregated connection,
responsibility
works
jid Job
eid
add asset
Conversion of ER to Relational
Employee Works_on Branch
manages
8. Representation of Aggregation
Create a schema with the primary key of the aggregated connection,
Conversion of ER to Relational
Branch = (bid, bname, asset)
Job = (jid, position, responsibility)
Works_on = (eid, bid, jid)
Manager = (mid, mgrname)
Manages = (eid, bid, jid, mid)