60 likes | 77 Views
Perform complete transformation steps for the E-R model of a real estate agency. Modify relations, create new ones, establish relationships.
E N D
OWNER 1 (1, N) own N (1, 1) incur (1, 1) (0, N) MAINTENANCE PROPERTY 1 N (0, N) 1 N (0, N) for rent (1, 1) ACCOUNT N (1, 1) N M (1, N) pay TENANT (1, N) Relational Database Design Relational Database Design Perform the complete transformation steps for the E-R Model of the ‘Real Estate Agency’ described in Topic4. 1 Topic 5 : Relational Database Design
The PROPERTY relation is modified: PROPERTY (Building#, Address, Value, Owner#) -- Relational Database Design Solution -- From Step1 OWNER ( Owner #, Owner Name, Owner Address) PROPERTY ( Building#, Address, Value) TENANT(Tenant#, Family Name, First Name, Contact Address, Phone#) MAINTENANCE (Maintenance#, Date, Type, Cost) ACCOUNT( Acct Receipt#, DateofPayment, TypeofAccount, AmountPaid) -- Step2:No weak entity -- Step3:no 1 To 1 relationship -- Step3 -- Step4:1 To N between OWNER and PROPERTY Topic 5 : Relational Database Design
The MAINTENANCE relation is modified to: MAINTENANCE(Maintenance#, Date, Type, Cost, Building#) The ACCOUNT relation is modified to: ACCOUNT( Acct Receipt#, DateofPayment, TypeofAccount, AmountPaid,Tenant#) The ACCOUNT relation is modified to: ACCOUNT( Acct Receipt#, DateofPayment, TypeofAccount, AmountPaid,Tenant#, Building#) -- -- -- Relational Database Design Solution -- Step4:1 To N between PROPERTY and MAINTENANCE -- Step4:1 To N between TENANT and ACCOUNT -- Step4:1 To N between PROPERTY and ACCOUNT Topic 5 : Relational Database Design
The RENT relation is created: RENT (Building#, Tenant#, LeasedPeriod, Bond) -- Relational Database Design Solution --Step5:M to N relationship between TENANT and PROPERTY -- Step6:no multivalued attribute. -- Step7:no ternary relatiosnhip - Topic 5 : Relational Database Design
Relational Database Design Solution -- Finally, the end result of the transformation can be listed as follows. Step 1 OWNER ( Owner #, Owner Name, Owner Address) PROPERTY (Building#, Address, Value, Owner#) TENANT(Tenant#, Family Name, First Name, Contact Address, Phone#) MAINTENANCE(Maintenance#, Date, Type, Cost, Building#) ACCOUNT( Acct Receipt#, DateofPayment, TypeofAccount, AmountPaid, Tenant#, Building#) RENT(Building#, Tenant#, LeasedPeriod, Bond) Step 4 Step 1 Step 4 Step 4 Step 5 Topic 5 : Relational Database Design