What is ER Diagram?
An Entity Relationship Diagram (ER Diagram) pictorially explains the relationship between entities to be stored in a database. Fundamentally, the ER Diagram is a structural design of the database. It acts as a framework created with specialized symbols for the purpose of defining the relationship between the database entities. ER diagram is created based on three principal components: entities, attributes, and relationships.
Salon Beta's Entity Relationship Diagram
Assumptions
- The inventory entity has consumables & tools with their Inventory_ID, Brand and quantity as its attributes.
- Customer can book a service and in that time booking_date will be saved.
- Service entity has Service_ID, Price, Service_Type as its attibutes and Service_Type attribute has three composite attributes called Facial, Hair_Style and Bridal.
- Customer entity has NIC, Cus_Name, Address attributes and Tel_No attribute as a multi-valued attribute.
- Customer can pay the bill to Cashier and at that time issued_date will be saved.
- Cashier entity has Cashier_ID and Cashier_Name as its attributes.
- Employee entity has Emp_ID, Emp_Name, Address, DOB attributes and Tel_No as a multi-valued attribute.
Entity Primary Key
- Inventory Inventory_ID
- Service Service_Code
- Employee Emp_ID
- Customer NIC
- Cashier Cashier_ID
Shorten name Meaning
- Emp_ID Employee’s ID
- Emp_Name Employee’s name
- DOB Date of birth
- Tel_No Telephone number
- NIC National identity card number
- Cus_Name Customer’s Name
Explanation
Salon Beta is a well-known beauty salon. Salon maintains one inventory. It stores inventory ID, size, tools, brands and consumables. The salon maintains the employees. Employees have an employee ID, employee name, addresses, date of birth, and phone numbers. Employees supply services. The service code, price, and type of service are also available as Facial, Hairstyle, and Bridal. One employee provides several services and there are several employees to provide one service. Customers book services. Store customer's NIC, name, address, phone numbers, and booking date. One customer can book several services and there are several customers to book one service. The salon maintains a cashier. There is a number and a name for a cashier. One customer pays for the cashier and several customers pay for one cashier. Saves the issued date for payment.
***
0 Comments