Database Schema: (10 Marks)
Create the necessary tables to store the following information:
A unique Contact_ID for each contact.
Customer Name, Address, Mobile Number, and Email Address.
A unique Vehicle_ID for each vehicle.
Vehicle Registration Number, Model, Manufacturer, Year of Manufacture, and Fuel Type.
Each customer may own multiple vehicles.
A unique Mechanic_ID for each mechanic.
Mechanic Name, Specialization, Experience, and Contact Number.
A unique Service_ID for each service transaction.
Service Date, Service Type (Periodic Service, General Repair, Engine Repair, Electrical Repair, Washing, etc.), Labour Charges, Spare Parts Cost, and Total Bill Amount.
Each service transaction must be assigned to one mechanic.
Multiple spare parts may be used during a service. Store the Part_ID, Part Name, Quantity, and Unit Price for each spare part. Your design should include:
An ER Diagram for the Vehicle Service Management System.
The final set of tables with all columns clearly defined.
Underline the Primary Key and specify all Foreign Keys.
Ensure that the database schema satisfies Third Normal Form (3NF).
The Vehicle Service Management System can be designed as a relational database in which customers, vehicles, mechanics, services, and spare parts are stored in separate but related tables. The main objective of the design is to avoid data redundancy, maintain data integrity, and represent the relationships between customers, their vehicles, mechanics, service transactions, and spare parts. The database can be implemented using SQL and can later be connected with a C++ program in the DBMS and C++ Lab for inserting, updating, searching, and displaying records. The main entities in the system are Customer, Vehicle, Mechanic, Service, Spare Part, and Service Part. A Customer can own many Vehicles, but every Vehicle belongs to one Customer. A Vehicle can have many Service transactions, while each Service transaction is related to exactly one Vehicle. A Mechanic can handle many Service transactions, but each Service transaction must be assigned to one Mechanic. A Service can use multiple Spare Parts, and the same Spare Part can be used in multiple service transactions. Therefore, a many-to-many relationship exists between Service and Spare Part, which is resolved using an intermediate table called Service_Part. The ER diagram can be represented as follows: ```text ┌──────────────────────┐ │ CUSTOMER │ ├──────────────────────┤ │ Contact_ID PK │ │ Customer_Name ______ _________ ________ ____ ____ _______ _________ ____ ___ ______.
__________ ________ ____ __________ _________ ____ ______ ________.
__________ __________ ___ ______ __________ ______.
_______ ________ _______ _______ ________ _____ ____ _________ ______ ___ ____ ___.
_________ __________ ______ ____ ___ ______ _________ ____.
_______ ___ __________ ___ ____ _______.
________ ________ __________ ________ _____ ________.
__________ ___ _____ ___ ________ _________ ___ _____ _______ ______ ______.
__________ _________ ___ ___ ____ ___ ____ ______ __________ _______ _______ ______.
_______ ______ ___ ______ _______ _____ ________ ____.
_______ __________ ______ __________ _____ ______ ___ ____ _____ ______ __________ ______.
________ ____ _______ _________ _____ _______ ___.
___ ___ ______ _________ _____ ___ ______.
__________ _______ ___ __________ ____ ________ __________ ____.
________ _______ _______ ________ _______ ________ _______ ____ _______ _________ _________.
_______ ______ _______ _______ _______ _________ ____ __________.
__________ _____ __________ _______ __________ ________ ___ __________ _________.
__________ ____ __________ _________ _______ ______ _______ ____ _______ _______ _________ _________.
_________ _________ _________ _______ ____ _____ ________ __________.
____ ___ __________ ___ _______ _________ _____ ___.
______ _____ _________ ____ __________.
____ _______ _________ _____ __________ ____ __________ ____ ________ ________ ______ _______.
____ ______ _______ ________ ___ ____ _____ ____.
_______ _______ ________ ______ ______ ____ ______ ___ ______.
__________ ____ ____ ______ _________ ________ _____ _______ _____.
__________ _________ _________ __________ _______ ______ ___ _____.
_________ _______ _____ _____ ____.
_____ __________ _______ __________ _______ _____ _____ _____.
________ ________ _______ _____ __________ _____ _____.
____ ______ ___ _________ ______ __________ ___ ____ ______ _____ ____ ______.
_________ ______ ____ _____ ________.
________ ___ _____ ______ __________ _________ _________ ______ ___ ___ ______ _____.
___ _________ ____ ___ _______ _____ _____ ___.
________ _______ ________ _____ ___ _______.
_______ _________ ______ ______ __________ ___ _______ ______.
___ _____ ________ ____ ______ ____ ______ ___ _____ ______ _____.
________ ____ ______ _____ ______ _________ ______ _________.
___ ______ ____ __________ __________ ______ __________ ____ __________ __________ ______.
__________ __________ _____ ______ __________ _______ _______ ___ ____ ___ ____ _____.
______ _______ ______ ________ _____ ____.
___ ______ ____ _______ _________ ________ ___ _________ _____.
_______ ________ _______ ______ ____ _______ __________.
___ ____ ___ _____ ____ __________ _____ ___.
________ ___ _____ _________ ________ ______ ______.
___ _________ ____ ____ ____ ___ ________ ________ _____ _______ ___.
_____ __________ _________ __________ _______ _______ _________ _______ ______ ______ _______ __________.
________ __________ ________ ________ ____ _____ ___.
__________ ______ _________ ___ _______ _____.
______ ______ ____ ___ ____ ___ __________ ___ _________.
_____ ______ _____ __________ _______.
________ ______ _____ _________ ______ ________.
__________ ______ _______ _______ _____ _______ _____.
________ _____ ____ _____ __________ ______ ______ __________ ___ ___ ______ _____.
____ ____ ___ ________ _____ ______ ___ ________.
___ ______ ________ ____ __________.
___ ____ ____ ______ _________ _________ ________ _____ _________ _________ _______ ________.
__________ _________ ________ _________ ___ _____ _________ ________.
____ _______ ___ _____ _______ __________ ___ _______ _________ _________ _______.
________ ________ _______ _____ ___ _____ _____ ____ ______ _______ ________.
______ ______ _______ ______ _________ ____ ____.
______ _______ ______ ______ ______ __________.
__________ _____ ________ _____ _____ ______ __________.
_____ _________ ______ ______ ____ _____ ______.
__________ _________ _________ _____ _______.
_________ _______ _____ _______ ________.
_________ ________ ___ _________ ___ ____.
__________ __________ ______ __________ _________.
_____ ______ _________ ____ _______ _____ __________ _________.
_______ _______ ___ ____ _________ ______.
__________ ________ _________ __________ ___ ________ ________ ____ _________ _______.
__________ ________ __________ _______ ________ __________ __________.
____ ______ _____ ________ ______.
_________ ____ ______ __________ ___ _____ ___ ____ ______ ________ _____.
________ ____ _________ _______ __________ ___ _______ __________.
_____ _____ ________ _______ ______ __________ __________ _______.
_________ __________ _______ ________ __________ ________ ____ ____ _______.
________ _________ __________ __________ ____.
______ ___ ___ ________ ______ _______ _____.
__________ _____ _____ ________ __________.
______ _____ _____ _____ ____ ______ ___ ________ _______ ____ _________.
____ _________ ______ _________ ______ ________ _____ ________ _________ ___ _____.
_____ _________ ___ ___ ___ _______.
________ ________ ___ ____ ________ _______ ______ _______.
________ _________ ____ ______ ___ ______ ____ _____ ____ _____ ________.
_________ ______ ______ _________ _____ __________ ___ _____ _______ _______.
____ ____ ___ __________ _________ _____ ________ _______ ________ ______ ________ _______.
__________ ________ ___ _____ ______ __________ ____ ________.
___ __________ __________ ____ _____ __________ _____ ___ _______ _________.
________ _______ ______ ________ ______ ___.
_______ _________ _______ ____ _____ ___ ______ ___ ______.
_________ ________ ___ ________ ______ _______ ________.
_______ _________ __________ __________ _______ __________ __________ ___ _________ __________.
_____ _________ _________ ________ _______ _________ ________ _______ _____.
_____ ___ _____ ____ ___.
___ ________ ______ ___ ____ __________.
____ ________ ________ ________ ______.
_______ _____ ___ ________ __________.
____ ______ ______ ______ _____ ___ ___ ____.
_______ __________ ____ _____ ___ __________ __________ ______ _________ _________ _______ __________.
__________ ______ _____ ____ ____ ___ ____ _______ ____ ________ _________ _______.
_______ ___ __________ ________ ____ __________ _______.
_____ ________ __________ ________ ________ ___.
______ ________ __________ _________ ________ _______ ____ ______ ______ _______ ________.
______ ____ _______ _____ ____ ___ __________ _____ ___ _______ ___.
_______ _____ _____ ______ ________ ______.
_________ _______ _________ _____ ____ ___ _______ __________ ________.
____ _______ ________ ________ _____ __________ __________ ________ _______ _______ _________.
_____ _____ ___ ______ __________ _____ _________ _______ ________ _____ ______.
__________ _________ ___ ________ ___ _________ _________ ____.
____ _____ ___ __________ _________ _____ ___ ________ ______ ______ ________.
__________ _________ ______ ________ ______ _________ ____.
___ __________ ____ ________ _____ _______.
__________ __________ ___ ___ ____ ________.
___ ________ ___ ____ ______ ____ ________ ________ ________ _______ ___ _________.
________ ____ _____ _________ _______ _______ ______.
______ __________ _____ _________ ___ _______ ____.
_____ ___ ______ _______ ____ ______.
___ ___ ____ __________ ______ ________ ______ _________.
___ ___ __________ __________ ___ ___ _____ ___ _____ __________ ________.
_________ _____ _____ __________ __________ ________ _________ _________.
_____ _____ ______ _____ _______ __________ _____ ______ ______ ____.
____ _____ ______ ________ ___ ________ ___ _______.
_______ ________ ____ ______ ___ ___ _____ ________ ___ ___ _____ __________.
__________ _______ _________ __________ __________.
__________ ________ _______ _________.
Get Full Answer on WhatsApp