Draw an ER model of the Banking database application considering the following constraints −
A bank has many entities.
Each customer has multiple accounts.
Multiple customers belong to a single branch.
Single customer can borrow multiple loans.
A branch has multiple employees.
Follow the steps given below to draw an ER model of the Banking database application −
The entity set has multiple instances in a given business scenario.
As per the given constraints the entity sets are as follows −
Customer − the relevant attributes are customerName, CustomerID, address.
Account − The relevant attributes are AccountNo, balance.
Branch − The relevant attributes are branchID, branchName, address.
Loan − The relevant attributes are loanNo, paymentMode, dateOfLoan, and amount.
Employee − The relevant attributes are empID, empName, dateOfJoin, experience, qualification.
CustomerID is the key attribute for a customer.
AccountNo is the key attribute for Account entities.
BranchID is the key attribute for branch entities.
LoanNo is the key attribute for a loan entity.
EmpID is the key attribute for an Employee entity.
One customer is enrolled by multiple accounts and one account for multiple customers. Hence, the relationship is many to many.
Many customers belong to one branch but one branch belongs to many customers. Hence, the relationship between customer and branch is many to one.
One customer can borrow multiple loans in the same way multiple loans can borrow a single customer, hence the relationship between customer and loan is one to many.
One branch has many employees and in the same way the number of employees works in a single branch.
The complete ER diagram is as follows −