Skip to content

The objective of this project is to demonstrate proficiency in data analysis using SQL. It involves setting up the Northwind e-commerce database, populating it with data, and then executing a series of analytical queries to extract meaningful insights.

Notifications You must be signed in to change notification settings

JKrish76/SQL-for-Data-Analysis

Repository files navigation

SQL for Data Analysis

📝 Project Objective: The objective of this project is to demonstrate proficiency in data analysis using SQL. It involves setting up the Northwind e-commerce database, populating it with data, and then executing a series of analytical queries to extract meaningful insights.

The queries in this project showcase the use of fundamental and advanced SQL concepts, including:

Data retrieval and filtering (SELECT, WHERE, ORDER BY)

Data aggregation (GROUP BY, SUM, AVG, COUNT)

Joining multiple tables (INNER JOIN, LEFT JOIN)

Complex querying with Subqueries

Simplifying analysis using Views

Database performance optimization with Indexes

🛠️ Tools Required:

Database: MySQL Server

Client: MySQL Workbench (or any other MySQL client)

🚀 Setup and Execution Instructions: Follow these steps to set up the database and run the analysis.

Step 1: Create the Database First, connect to your MySQL server using MySQL Workbench. Open a new query tab and execute the following command to create the database container:

Select the northwind.sql file.

Execute the entire script to create the database structure.

Step 2: Insert the Data This step populates the newly created tables with data.

Go to File > Open SQL Script...

Select the northwind-data.sql file.

Execute the entire script. The tables will now be filled with data.

Step 3: Run the Analysis Queries This is the final step, where the analysis is performed.

Go to File > Open SQL Script...

Select the task_query.sql file.

Execute the entire script. This will run all the analytical queries required for the task. The results for each SELECT statement will appear in the "Result Grid" in MySQL Workbench.

🗂️ File Descriptions:

northwind.sql: The schema file. Contains all the CREATE TABLE statements to build the database structure.

northwind-data.sql: The data file. Contains all the INSERT INTO statements to populate the database.

task_query.sql: The analysis file. Contains all the required queries that perform the data analysis and answer specific business questions.

Screenshots Folder: This folder contains the output images from each SELECT query executed from the task_query.sql file.

About

The objective of this project is to demonstrate proficiency in data analysis using SQL. It involves setting up the Northwind e-commerce database, populating it with data, and then executing a series of analytical queries to extract meaningful insights.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published