Lab6 - ERD
Lab6 - ERD
1
Entity Relationship Diagram:
Advised by (1,1)
Offered
Course(1,1)
Case Study 2:
Consider the ER diagram shown in Figure 2 for part of a BANK database. Each
bank can have multiple branches, and each branch can have multiple accounts
and loans. Each BANK has a unique Code, as well as a Name and Address. Each
BANK is related to one or more BANK-BRANCHes, and the BranhNo is unique
among each set of BANK-BRANCHes that are related to the same BANK. Each
BANK-BRANCH has an Address. Each BANK-BRANCH has zero or more LOANS
and zero or more ACCTS. Each ACCOUNT has an AcctNo (unique), Balance, and
Type and is related to exactly one BANK-BRANCH and to at least one
CUSTOMER. Each LOAN has a LoanNo (unique), Amount, and Type and is related
to exactly one BANK-BRANCH and to at least one CUSTOMER. Each CUSTOMER
has an SSN (unique), Name, Phone, and Address, and is related to zero or more
ACCOUNTs and to zero or more LOANs.
2
1. Entity types: BANK, ACCOUNT, CUSTOMER, LOAN
2. Weak entity type: BANK-BRANCH.
Partial key: BranchNo.
Identifying relationship: BRANCHES.