CS603 Assignment Number 1
CS603 Assignment Number 1
Question no1:
Virtual University of Pakistan
(a) Database Design Diagram for Branches and Employees
Relationship:
One Branch employs many Employees.
One Employee belongs to one Branch.
Type: One-to-Many Relationship
Database Design Diagram:
Table Names
Branches
Employees
Customers
Accounts
Services
Account_Services
Foreign Key
Table Name Columns Primary Key (PK)
(FK)
Branch_ID, Branch_Name,
Branches Branch_ID -
Branch_Location
Employee_ID,
Employee_Name,
Employees Employee_ID Branch_ID
Employee_Position,
Branch_ID
Customer_ID,
Customer_Name,
Customers Customer_ID -
Customer_Address,
Customer_Phone
Account_ID, Account_Type,
Accounts Account_ID Customer_ID
Balance, Customer_ID
Service_ID, Service_Name,
Services Service_ID -
Service_Description
Account_Service_ID, Account_ID,
Account_Services Account_Service_ID
Account_ID, Service_ID Service_ID