This project involves analyzing a Music Store Database using SQL queries to extract insights and uncover trends related to music sales, customer behaviors, and artist popularity. The analysis is implemented through a series of SQL queries each designed to address specific questions related to the business operations of a hypothetical music store.
- SQL data analysis.sql - Contains all the SQL queries used to perform the database analysis
- Music Store database.sql - Contains data used is analysis
- Music database schema.png - Can be used to understand data
This analysis covers a range of queries to explore different aspects of the database:
- Senior-most Employee: Identifies the most senior employee based on job title.
- Top Countries by Invoices: Lists countries generating the most invoices.
- Top Invoice Values: Finds the top three values of total invoices.
- City with Highest Sales: Searches for the city with the highest sum of invoice totals.
- Best Customer: Determines the customer who has spent the most money.
- Rock Music Listeners: Lists all customers who prefer Rock music.
- Top Rock Artists: Identifies the top 10 rock artists by track counts.
- Long Track List: Compiles tracks longer than the average track length.
- Spending by Customer on Artists: Calculates total spending by each customer on artists.
- Popular Music Genre by Country: Identifies the most popular music genre in each country.
- Top Spenders by Country: Shows the top spender in each country.
Ensure you have a SQL-compatible database management system (DBMS) installed, such as MySQL, PostgreSQL, or SQLite, to run the queries contained in the SQL file.
- Clone the repository locally:
git clone https://github.com/Harshit0699/MUSIC-STORE-DATAB...
- Open your DBMS and create a connection to your database server.
- Import the Music Store Database to your DBMS (Database file not included in this repository).
- Open the
SQL data analysis.sql
file and run the queries in your DBMS to see the results.
Contributions to enhance the current analysis or extend the range of query topics are highly appreciated. Please fork the repository and submit a pull request with your proposed changes.
This project is open-sourced under the MIT License.
For any further questions or comments, feel free to reach out to (https://github.com/Harshit0699).