π Contoso Database Project using MySQL π Project Overview
This project demonstrates the use of SQL queries on the Contoso Database using MySQL. The main objective is to showcase how SQL clauses such as WHERE, GROUP BY, ORDER BY, LIMIT, and JOIN can be applied to retrieve, filter, organize, and analyze data efficiently.
π― Problem Statement
The project addresses the challenge of extracting meaningful insights from structured datasets by:
Filtering records with specific conditions (WHERE).
Aggregating and grouping data (GROUP BY).
Sorting results (ORDER BY).
Limiting output for concise analysis (LIMIT).
Combining data from multiple tables (JOIN).
π Dataset
The project uses the Contoso Database, which contains information about:
π Calendar dates
π± Currency exchange rates
π¦ Products and categories
π Business-related transactions
π οΈ SQL Commands Implemented π WHERE Clause
Find all dates from the calendar table that fall on a Monday.
Retrieve all exchange rates where FromCurrency = 'USD'.
Get all records where WorkingDay = 1.
Filter dates in January.
π GROUP BY Clause
Group currency exchanges by FromCurrency and count them.
Find the average exchange rate for each currency.
Group calendar entries by DayofWeek.
Find maximum exchange rate per currency.
π½ ORDER BY Clause
Order calendar by date (ascending).
Sort records by MonthNumber and DayofWeekNumber.
Order exchange rates by ToCurrency.
βοΈ LIMIT Clause
Retrieve the top 5 highest exchange rates.
Limit results to 10 entries for January.
Show 5 most recent working days.
π JOIN Clause
List all products with their categories.
β Conclusion
The project demonstrates the power and flexibility of SQL in analyzing structured datasets. By applying different SQL clauses on the Contoso Database, we successfully extracted valuable insights useful for business analytics and decision-making.
π Technologies Used
MySQL
Contoso Database
SQL Queries (DQL)
π Author
π€ Krish Mukesh Sangani Guided by: Anukul Sir
for more preference:-
β’ Designed and executed complex SQL queries on the Contoso database using MySQL to extract, filter, and organize structured business data. β’ Utilized WHERE, GROUP BY, ORDER BY, LIMIT, and JOIN clauses to retrieve targeted datasets, perform aggregations, and generate actionable insights. β’ Conducted data filtering and aggregation to identify trends, calculate averages, and segment data for detailed analysis. β’ Created optimized JOIN operations to combine multiple tables, enabling richer and more comprehensive reporting. β’ Implemented sorting and limiting queries to streamline analysis and improve query performance for large datasets.