Skip to content

πŸ“Š A MySQL project answering 15 real-world business questions on pizza sales using advanced SQL queries like joins, aggregations, subqueries, and window functions.

Notifications You must be signed in to change notification settings

TheMLengineer07/Pizza_sales__SQL_Project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

2 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ• MySQL Pizza Sales Analysis

This project is a comprehensive analysis of a pizza sales database using MySQL. It consists of 15 business-oriented questions ranging from basic to advanced SQL queries. The goal is to extract meaningful insights using real-world SQL techniques such as joins, aggregations, window functions, and subqueries.


🧠 Questions Covered

βœ… Basic

  1. Total number of orders placed
  2. Total revenue from pizza sales
  3. Highest-priced pizza
  4. Most common pizza size
  5. Top 5 most ordered pizza types

βœ… Intermediate

  1. Quantity of each pizza category ordered
  2. Order distribution by hour
  3. Category-wise pizza distribution
  4. Average number of pizzas ordered per day
  5. Top 3 pizza types by revenue

βœ… Advanced

  1. % revenue contribution of each pizza type
  2. Cumulative revenue over time
  3. Top 3 pizzas by revenue for each category

πŸ“‚ Folder Structure

mysql-pizza-sales-analysis/
β”œβ”€β”€ README.md               # This file
β”œβ”€β”€ Questions.txt           # All 15 questions
β”œβ”€β”€ solutions.sql           # SQL queries for each question
β”œβ”€β”€ assets/                 # (Optional) ERD, screenshots
β”‚   └── schema.png
β”œβ”€β”€ docs/                   # (Optional) Summary report
β”‚   └── Pizza_SQL_Report.pdf


πŸ“¦ Tools Used

* MySQL 8.0+

* MySQL Workbench / DBeaver

* SQL Window Functions

* Joins, Aggregates, Subqueries

πŸ“Š Key Features

* Daily, hourly, and category-wise sales analysis

* Cumulative revenue using SUM() OVER()

* Top pizzas by quantity and revenue

* Percentage-based contribution calculations

πŸ› οΈ How to Use

* Load your database using the provided schema.

* Open solutions.sql in MySQL Workbench.

* Run each query to see insights based on real data.

* Modify or extend the queries to explore further.

πŸ‘¨β€πŸ’» Author

Prabhav Gupta
πŸ“§ 2010prabhavgupta@gmail.com
πŸ”— www.linkedin.com/in/prabhav91



About

πŸ“Š A MySQL project answering 15 real-world business questions on pizza sales using advanced SQL queries like joins, aggregations, subqueries, and window functions.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published