← Back
ITSC 3160Oracle LiveSQLLucidchartSQLDatabase Design

Dealership Inventory & Sales Analysis

A full database design and implementation project for a car dealership, built as part of Database Design & Implementation (ITSC 3160). The system manages vehicles, customers, employees, manufacturers, and transactions in a normalized relational database deployed on Oracle LiveSQL.

my role

On a team of four, I was responsible for logical diagram implementation and data entry, translating the conceptual ER model into a fully normalized logical schema and populating all six tables with realistic seed data for testing.

overview

The database handles day-to-day dealership operations: customer browsing, vehicle listing, transaction processing, and employee management. Six core entities are linked through foreign key constraints enforcing referential integrity across the full dataset. The schema satisfies 1NF, 2NF, and 3NF normalization throughout.

entity relationship diagram

ManufacturersPKIDModelsPKIDVehiclesPKVINTransactionsPKIDCustomersPKIDEmployeesPKID
Single bar = One (mandatory)
Crow's foot = Many
Line = Relationship
All relationships are One-to-Many (1:N)

logical diagram

ManufacturersPKIDNUMBERNameVARCHAR2(50)CountryVARCHAR2(50)Year_FoundedNUMBERParent_CompanyVARCHAR2(50)ModelsPKModel_IDNUMBERModel_NameVARCHAR2(50)FKManufacturerIDNUMBERMSRPNUMBERYear_IntroducedNUMBERVehiclesPKVINVARCHAR2(17)FKModel_IDNUMBERYearNUMBERColorVARCHAR2(30)PriceNUMBEREmployeesPKIDNUMBERNameVARCHAR2(50)PositionVARCHAR2(50)FKManager_IDNUMBERHire_DateDATETransactionsPKIDNUMBERFKVINVARCHAR2(17)FKCustomerIDNUMBERFKEmployeeIDNUMBERValueNUMBERCustomersPKIDNUMBERNameVARCHAR2(50)AddressVARCHAR2(100)PhoneVARCHAR2(15)EmailVARCHAR2(50)
PKPrimary Key: unique row identifier
FKForeign Key: references another table's PK
Dashed line = FK → PK reference

normalization

1NF

All tables have atomic values, no repeating groups or comma-separated fields.

2NF

All non-key attributes fully depend on the entire primary key.

3NF

No transitive dependencies, e.g. MSRP lives in Models, not Vehicles.

sample queries

All vehicles by manufacturer

SQL
SELECT v.VIN, mo.Model_Name, v.Year, v.Color, v.Price
FROM Vehicles v
JOIN Models mo ON v.Model_ID = mo.Model_ID
JOIN Manufacturers ma ON mo.ManufacturerID = ma.ID
WHERE ma.Name = 'Porsche';

Inventory vehicles by model

SQL
SELECT v.VIN, mo.Model_Name, v.Year, v.Color, v.Price
FROM Inventory v
JOIN Models mo ON v.Model_ID = mo.Model_ID
WHERE mo.Model_Name LIKE 'Macan%';

Full transaction details

SQL
SELECT t.ID, c.Name AS Customer, e.Name AS Employee,
       v.VIN, mo.Model_Name, v.Color, t.Value
FROM Transactions t
JOIN Customers c  ON t.CustomerID = c.ID
JOIN Employees e  ON t.EmployeeID = e.ID
JOIN Vehicles v   ON t.VIN = v.VIN
JOIN Models mo    ON v.Model_ID = mo.Model_ID;

Transactions for customer 'Richard' with red vehicle

SQL
SELECT t.ID, c.Name, v.VIN, mo.Model_Name, v.Color, t.Value
FROM TransactionDetails t
JOIN Customers c ON t.CustomerID = c.ID
WHERE c.Name LIKE '%Richard%'
AND v.Color = 'Red';

Query Results

All Porsche Macan vehicles

VINModelYearColorPrice
WP1AA2A57LLB125Porsche Macan2020Black$60,000.12
WP1AA2A57LLB123Porsche Macan2019Blue$49,887.12
WP1AA2A57LLB125Porsche Macan2021Orange$52,000.12
WP1AA2A57LLB123Porsche Macan2021Silver$53,000.12
WP1AA2A57LLB125Porsche Macan2019White$61,545.12
WP1AA2A57LLB123Porsche Macan2020Black$42,753.12
WP1AA2A57LLB125Porsche Macan2022Turquoise$87,000.12

Transaction details

Transaction IDCustomerVINModelColorValueEmployee
251209066Alex AndersonWP1AA2A57LLB123Porsche MacanRed$42,000.00Sarah Johnson
271206396Alex KolcarykWP1AA2A57LLB125Porsche MacanBlack$60,000.12Gracie Del
261206366Richard JacksonWP1AA2A57LLB123Porsche MacanRed$42,000.00Michael Brown
266302465Robert JamisonWP1AA2A57LLB123Porsche MacanBlue$49,887.12John Carter
Download Full Report