. Design an ER-diagram for a bank that implements the following requirements. The database you design should store information about customers, accounts, branches and employees
• Customer: Customers are identified by their SSN. For each customer we store a name, multiple phone numbers (one or more), and an occupation.
• Account: Accounts are identified by an account number and the branch they belong to. For each account we store a balance and the type of account (e.g., savings).
– An account belongs to one or more customers. A customer can have any number of accounts.
– An account belongs to exactly one branch. Obviously, branches can have multiple accounts (branches are not required to have accounts).
• Branch: A branch is identified by a unique branch code. For each branch we want to store a location and number of employees.
• Employee: Employees are identified by their SSN. For each employee we store a name and salary.
– An employee works for exactly one branch. Branches have one or more employees.
– An employee is the contact for zero or more customers. Every customer has at most one employee as a contact.
Solution:
Explanation:
The above ER diagram demonstrates what the question is.
The rectangle box is an entity
Every Pair of entities has two relations as mentioned in question.
Attributes are mentioned in oval shape.
Diamond is a relationship
Get Answers For Free
Most questions answered within 1 hours.