This project analyses warehousing operations and order management using MySQL. By leveraging techniques such as JOINs, functions, logical operators, and subqueries, we uncover insights about warehouse performance, order trends, and employee statistics.
| Column Name | Description |
|---|---|
warehouse_id |
Unique identifier for each warehouse. |
warehouse_alias |
Alias or name of the warehouse. |
maximum_capacity |
Maximum storage capacity of the warehouse. |
employee_total |
Total number of employees. |
state |
Location of the warehouse. |
| Column Name | Description |
|---|---|
order_id |
Unique identifier for each order. |
customer_id |
Unique identifier for the customer. |
warehouse_id |
ID linking the order to its warehouse. |
order_date |
Date the order was placed. |
shipper_date |
Date the order was shipped. |
To get started, download MySQL DBMS from the official MySQL website: Download MySQL.
Follow the on-screen instructions, choosing the appropriate custom settings for your SQL Server and Workbench. Remember to set a secure password during the setup.
Open MySQL Workbench: Launch MySQL Workbench and log in using the password you set during installation.
Connect to the Server: Ensure you’re connected to the server using the Navigator. For more information on using the Navigator, refer to the MySQL Workbench Navigator Documentation.
Import Datasets: Import the warehousewarehouse and warehouseorders datasets into MySQL Workbench. You can find the detailed steps in the Import and Export Management Guide.
Load the Datasets: Execute the following SQL queries to load and view your datasets:
SELECT *
FROM warehousewarehouse;
SHOW COLUMNS
FROM warehousewarehouse;
SHOW COLUMNS
FROM warehouseorders;
SELECT *
FROM warehouseorders;
SELECT
WW.warehouse_id,
WW.warehouse_alias,
COUNT(WO.order_id) `Total Orders`
FROM warehousewarehouse WW
LEFT JOIN warehouseorders WO
ON WW.warehouse_id = WO.warehouse_id
GROUP BY
WW.warehouse_id,
WW.warehouse_alias;
SELECT
WW.warehouse_id,
WW.warehouse_alias,
WW.employee_total `Employees`,
COUNT(WO.order_id) `Orders`
FROM warehousewarehouse WW
LEFT JOIN warehouseorders WO
ON WW.warehouse_id = WO.warehouse_id
GROUP BY
WW.warehouse_id,
WW.warehouse_alias,
WW.employee_total;
SELECT
WW.warehouse_id,
WW.warehouse_alias,
MAX(WO.order_date) `Recent Order Date`
FROM warehousewarehouse WW
LEFT JOIN warehouseorders WO
ON WW.warehouse_id = WO.warehouse_id
GROUP BY
WW.warehouse_id,
WW.warehouse_alias;
SELECT
warehouse_alias,
maximum_capacity
FROM warehousewarehouse
WHERE maximum_capacity = (
SELECT MAX(maximum_capacity)
FROM warehousewarehouse);
SELECT
order_id,
customer_id,
warehouse_id,
order_date,
shipper_date
FROM warehouseorders
WHERE order_date = shipper_date;
SELECT
WW.warehouse_id,
WW.warehouse_alias,
COUNT(WO.order_id) `Order Count`
FROM warehousewarehouse WW
JOIN warehouseorders WO
ON WW.warehouse_id = WO.warehouse_id
GROUP BY
WW.warehouse_id,
WW.warehouse_alias
ORDER BY `Order Count` DESC
LIMIT 3;
MySQL Script: The full script is available in the project repository for download.
Insights Summary: Key takeaways from the data analysis (optional).
Presentation Deck: A visual summary of findings (optional).
Contact If you have questions or suggestions, feel free to reach out to [oscarsim3on@gmail.com or medium.com/@oscarsim3on].