π SQL Proficiency Demo β MySQL Project
A fully working MySQL database project showcasing core SQL concepts used in real-world systems. The project includes schema design, sample data, indexes, views, transactions, joins, aggregations, reporting queries, and more β all written using clean, beginner-friendly MySQL syntax.
This repository is meant to demonstrate SQL skills for interviews, resumes, and technical evaluations.
π Features Demonstrated βοΈ Database & Schema Design
Normalized e-commerce schema
Tables: users, products, suppliers, orders, order_items, inventory, employees, departments, audit_logs
Primary keys, foreign keys, constraints
βοΈ Core SQL (DML + DDL)
CREATE, ALTER, DROP
INSERT, UPDATE, DELETE
Bulk sample data for testing
βοΈ Select Queries
WHERE, AND/OR, LIKE, IN, BETWEEN
Sorting + Limiting: ORDER BY, LIMIT
βοΈ Joins
INNER JOIN, LEFT JOIN, RIGHT JOIN
SELF JOIN for employee-manager hierarchy
CROSS JOIN for Cartesian examples
βοΈ Aggregation & Grouping
GROUP BY, HAVING
Category revenue report
User lifetime spend
Monthly revenue analytics
Cohort analysis (first order month)
βοΈ Subqueries & UNION
Scalar subqueries
Subqueries in UPDATE statements
UNION & UNION ALL
βοΈ Transactions
START TRANSACTION
SAVEPOINT & ROLLBACK
Demonstrates atomic operations
βοΈ Views
customer_order_summary view for analytics
βοΈ Indexing
Email index
Category index
User-order index
Inventory lookup index
βοΈ Reporting Queries
Monthly revenue
Low inventory alerts
Customer RFM-like metrics
Top-selling categories
π οΈ Tech Stack
MySQL 8+
Standard SQL (features covered in beginner-friendly SQL notes)
No advanced PG-only features
Portable, interview-approved syntax
π Project Structure / βββ README.md # You're reading it βββ demo_mysql.sql # Main SQL script (schema + data + queries) βββ screenshots/ # Optional: results, ERD diagrams, etc.
π§ͺ How to Run
Install MySQL 8+
Open MySQL Workbench OR terminal
Run:
SOURCE demo_mysql.sql;
Execute the query sections inside the script:
Demonstration queries
Reporting queries
View + Index checks
Transaction examples
The database demo_mysql will be created automatically.
π― What This Project Proves (For Recruiters)
This project showcases your ability to:
Design relational databases thoughtfully
Write optimized SQL queries
Use joins/aggregations for business reporting
Handle transactions safely
Index tables for performance
Produce analytics directly from SQL
Think like an engineer, not just run queries
Great for:
Data Analyst roles
Backend roles
Database Engineering
Product Analyst / BI
Internship applications
Placements / fresher roles
π Sample Outputs
You can add screenshots later, such as:
ERD diagram
Output of customer summary
Output of monthly revenue
Low inventory alerts
Putting visuals in GitHub dramatically increases recruiter engagement.
π License
MIT License β free for anyone to use or build on.
β Contribute
Want to improve this project?
Add stored procedures
Add triggers
Add a bigger dataset (500β10k rows)
Add sample analytics dashboards
Pull requests welcome.