0% found this document useful (0 votes)
11 views4 pages

Database Project

Uploaded by

limnix99
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views4 pages

Database Project

Uploaded by

limnix99
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

OMBA 5305 Data Management in Business: Project I Database Design

Part 1: Data Management (8 points)

Functional Area:
Chosen functional area: Retail Order Management

Explanation of Area/Process:
Retail order management involves tracking and processing customer orders in a retail
business. It focuses on maintaining accurate records of customer details, orders placed, and
inventory levels. This database aims to:
- Facilitate real-time order processing.
- Enable efficient inventory tracking and updates.
- Support personalized customer interactions.
- Ensure data integrity and support decision-making.

By managing these processes, the database contributes to operational efficiency and


improves customer satisfaction. Retail order management is a critical area that ties together
sales, inventory, and customer service operations.

Entity Relationship Diagram (ERD):


The ERD includes three entities:

1. Customer:

- Attributes: Customer_ID (Primary Key), First_Name, Last_Name, Email, Phone_Number,


Address.

- Justification: Captures essential customer information to facilitate order placement,


communication, and personalized service.

2. Order:

- Attributes: Order_ID (Primary Key), Order_Date, Customer_ID (Foreign Key),


Total_Amount, Status.

- Justification: Records details of orders placed by customers, linking each order to the
respective customer and tracking its status.

3. Product:

- Attributes: Product_ID (Primary Key), Product_Name, Category, Price, Stock_Quantity.

- Justification: Tracks product details, including stock levels, to ensure availability and
accurate order fulfillment.
Relationships:
- Customer to Order: One-to-Many (A single customer can place multiple orders over time).

- Order to Product: Many-to-Many (Each order can include multiple products, and each
product can be part of multiple orders).

These relationships are implemented through a junction table (Order_Product) that tracks
the quantity of each product in an order.

Write-Up:
This database design supports retail order management by integrating critical components:
customers, orders, and products. It ensures:
- Data consistency through well-defined relationships.
- Accurate tracking of customer orders and product inventory.
- Scalability to include additional features like supplier tracking or sales analysis.

The database design can also support different business strategies, such as offering
promotions based on customer purchase history or optimizing inventory based on sales
trends.

Part 2: Create the Database (12 points)

SQL Implementation:
1. Create the Tables:

CREATE TABLE Customer (


Customer_ID INT PRIMARY KEY,
First_Name VARCHAR(50),
Last_Name VARCHAR(50),
Email VARCHAR(100),
Phone_Number VARCHAR(15),
Address TEXT
);

CREATE TABLE Product (


Product_ID INT PRIMARY KEY,
Product_Name VARCHAR(100),
Category VARCHAR(50),
Price DECIMAL(10, 2),
Stock_Quantity INT
);

CREATE TABLE `Order` (


Order_ID INT PRIMARY KEY,
Order_Date DATE,
Customer_ID INT,
Total_Amount DECIMAL(10, 2),
Status VARCHAR(20),
FOREIGN KEY (Customer_ID) REFERENCES Customer(Customer_ID)
);

CREATE TABLE Order_Product (


Order_ID INT,
Product_ID INT,
Quantity INT,
PRIMARY KEY (Order_ID, Product_ID),
FOREIGN KEY (Order_ID) REFERENCES `Order`(Order_ID),
FOREIGN KEY (Product_ID) REFERENCES Product(Product_ID)
);

2. Populate Each Table with Records:

INSERT INTO Customer VALUES (1, 'John', 'Doe', '[email protected]', '123-456-


7890', '123 Elm St');
INSERT INTO Customer VALUES (2, 'Jane', 'Smith', '[email protected]', '987-654-
3210', '456 Oak St');

INSERT INTO Product VALUES (101, 'Laptop', 'Electronics', 1200.00, 50);


INSERT INTO Product VALUES (102, 'Headphones', 'Accessories', 100.00, 200);

INSERT INTO `Order` VALUES (1001, '2024-12-01', 1, 1300.00, 'Shipped');


INSERT INTO `Order` VALUES (1002, '2024-12-02', 2, 100.00, 'Pending');

INSERT INTO Order_Product VALUES (1001, 101, 1);


INSERT INTO Order_Product VALUES (1001, 102, 1);
INSERT INTO Order_Product VALUES (1002, 102, 1);

3. Run SELECT Queries:

SELECT * FROM Customer;


SELECT * FROM Product;
SELECT * FROM `Order`;
SELECT * FROM Order_Product;
Summary:
This project showcases the design and implementation of a database tailored for retail
order management. The ERD and SQL implementation ensure:
- Accurate data representation for key business processes.
- Integrity and consistency through relational structures.
- Scalability for incorporating advanced features or aligning with business strategies.

By addressing operational challenges and supporting decision-making, this database design


aligns with the strategic objectives of retail businesses.

You might also like