Back to articles list Articles Cookbook
13 minutes read

SQL Code Project Examples

Want to practice SQL and add projects to your portfolio? This article covers 10 beginner-friendly project ideas, complete with detailed steps and data sources to help you get started.

Building an SQL project is a great way to practice your querying skills and is a great addition to your portfolio if you are a beginner. In this article, we will go through 10 ideas for SQL code projects that are suitable for beginners. We will discuss each idea in detail, including where to get the data and the step-by-step approach to creating the project.

For your project, you can create your own database or use an existing one. At LearnSQL.com, we have compiled a course with 7 practice databases where you can test out your queries right in your browser. The course includes a university database, a store database, an airport database, and more! Some of these databases will be used for the project ideas below; I’m sure you will also be inspired with your own ideas.

Want to check out what a complete SQL project looks like? We recently created a Sales Dashboard for the AdventureWorks database. The article has a detailed description of the process for creating an SQL project. After you are finished with that project, check out how to include an SQL project in your CV.

SQL Code Project Examples and Ideas

1. Class Leaderboard

Overview

The first project idea is to use SQL for analyzing university student performance. This involves examining individual student grades, evaluating the effectiveness of lecturers in delivering courses, and assessing the overall performance of student groups per semester.

Where to get the data

Our practice course SQL Practice Databases contains a sample university database (in its free portion!). The university database contains 6 tables full of realistic data about lecturers, courses, and students together with their performance. You can use this database to explore and write queries for free, right in the browser!

Step-by-step instructions

Go to the course SQL Practice Databases and start it for free. The first database is the university database. First, explore the database by yourself. Then, write down a few questions that you would like your SQL project to answer. These could be:

  • What was the average performance of students for each subject during the last semester?
  • How many people failed the SQL course?
  • What teacher taught the most students this semester?

Use SQL to answer these questions, then analyze the results. Optionally, you can visualize the data with tools like PowerBI  to complete your SQL project.

Resources

2. Art Portfolio Manager

Overview

How about managing your artistic or crafting portfolio with SQL? Maybe you create paintings, models, or photos. Or maybe you enjoy crafts like crochet, decoupage, sewing, knitting, or similar activities. Whatever you’re into, cataloging your work can be incredibly helpful.

SQL Code Project Examples

This SQL project tackles sorting through endless folders of data or trying to compile a list of materials you used for your last creation. Let the database do the heavy lifting!

Where to get the data

First, create your dataset. Take some examples of your existing work and note which properties you would like to record. These can include:

  • The title and date of the work.
  • Medium and style.
  • Equipment and/or materials, if applicable.
  • Location, time spent, and other information specific to your niche.

You can use this outline to create a database for your works. If you have some strictly categorical values (e.g. equipment, materials), consider moving them into a separate table, where you can store some additional information.

Step-by-step instructions

Create the database as described above. Every time you complete a piece of work, update the database with a new record; you will have tables full of data in no time!

Then you can query the database to answer questions like:

  • How often does each material get used?
  • How many photos of each country are there?
  • What work took the longest to create?

You may also look into creating an overview of the data you have gathered. For example, you could create a timeline of different art pieces or visualize the time spent on each work from the past year.

Resources

3. Web Traffic Analytics

Overview

Here’s a common real-world analytics question: How much traffic does our website get? The universal followup is: How do we improve our website traffic? This is another SQL project idea: analyzing visitor traffic for a website.

This project will focus on analyzing the performance of individual web pages and topics throughout different time periods, giving you experience with real-world business problems.

Where to get the data

If you have your own website, you can get the data for this project using Google Analytics. If you do not have access to a website, our SQL Practice Databases course has a website traffic database prepared just for you. You can query the database right in your browser, no need to download or install anything!

Step-by-step instructions

Create some questions that would make sense in a business setting and that the database will be able to answer. For example:

  • What was the most visited page this month?
  • What is the average page view rate for each topic?
  • What tags have the best click rate?
  • What is the average lifetime of a page after publication?

You can also explore each page’s statistics, individually:

  • View/unique view rates (per day/week/month)
  • Bounce rate
  • Average time spent on the page

Resources

4. Your Own Netflix Wrapped

Overview

Would you like to make your own Wrapped for Netflix? With the power of SQL, you can get much more insight than what Netflix provides on its own. Netflix will let you download your watch history data, which you can analyze and visualize in any form you’d like!

Where to get the data

You can download your viewing data from Netflix's Account Settings page:

  • Log into Netflix in your browser.
  • Go to Account Settings -> Profile & Parental Controls -> Viewing activity.
  • Scroll to the bottom and hit Download all. You will get a CSV file with your viewing history.

Step-by-step instructions

Once you have the data, import it into your database. Try analyzing the following topics:

  • What was the most watched series this year?
  • What was the average daily watchtime?
  • How much time was spent watching Netflix on the weekends?
  • What was the longest binge-watching session?
  • Which months have the highest number of different shows watched?

Resources

5. Real Estate Market Analysis

Overview

An SQL project analyzing your local real estate market can be a great example of hands-on practice for real world problems. Skills you will practice in this project can be transferable to a lot of business analytics jobs, and you can get some insights into a relatable topic.

Where to get the data

This project requires a ready-made dataset. You can find a dataset like this on Kaggle for almost any region you can think of! Try searching keywords like “real estate” or “housing”, as well as the name of a country or region that you would like to use in this project.

Step-by-step instructions

Once you have a dataset ready, import it into a database. You can analyze topics like these:

  • What was the average sale price in your zip code in 2024?
  • How many houses were sold for below their asking price in your region in the past year?
  • Which neighborhoods have the best value for money options?
  • What is the biggest house that you can get for under $100,000?
  • Are there any houses that sold for more than the asking price?

Price-related data can also be visualized on a map for a more readily understandable result.

Resources

6. Sales Analysis

Overview

Analyzing sales from a realistic business dataset can be a great way to practice real-world queries. If you have access to sales data from a business you work for, analyze it with SQL. If you don’t, our SQL Practice Databases course contains the Northwind store database, a sample store database prepared by Microsoft that’s perfect for practicing sales reports.

SQL Code Project Examples

An SQL project revolving around a database like this can include different sales metrics, customer behaviour analysis, product ratings, and lots of other data!

Where to get the data

Check out the Northwind store database from our SQL Practice Databases course. It contains 6 tables describing operations of an online store, including customer information, orders, and products and their categories.

Step-by-step instructions

Explore the database with basic queries and JOINs. Analyze the data by answering questions like these:

  • What countries have had the biggest order volumes this year?
  • What was the most popular product in each category?
  • Which advertisement channel was the most effective?
  • What was the average order size for each country in the past year?
  • How does each advertisement channel correlate to order sizes?
  • How many orders, on average, does a customer place per year?

Resources

7. 3D Printing Job Queue

Overview

Managing a fleet of 3D printers, or even one, can sometimes be a hassle. If you want to print several models, one after another, it can be hard to keep track of the queue. Why not put all the printing requests in a database? Together with a clear print order and filament use statistics, you can automate your printer to interact with the database for some extra SQL power!

Where to get the data

You can design a simple database that includes information about each model that you want to print, the filament used, the start and end times, and the model’s position in the queue. Every time you want to print a new model, just add it to the database in the next available spot in the queue. After some uptime, the database will be full of data for you to analyze.

Step-by-step instructions

Gather a substantial amount of data from your print job queue. Once you have it, you can analyze it using questions like:

  • Which model(s) is being printed right now?
  • What is the next model in the queue?
  • How much time in total was spent printing today?
  • At what speed is the filament being used?
  • How many specific models can be finished per day, considering current print speeds?

Resources

8. Gaming Leaderboard

Overview

If gaming lies close to your heart, why not practice on an esports tournament database? An SQL project like this would be centered around a database of different tournaments, players, games, and scores. You can calculate different players’ performance in each of the tournaments, the attendance and popularity of each tournament, the top ranks of players in each game, and many more metrics!

SQL Code Project Examples

Where to get the data

You can ask your local university, club, tournament organizers, etc. for this data – or make an imaginary competition of your own. You can also use publicly available data from famous esports tournaments. You will probably have to create your own database for a project like this.

Step-by-step instructions

Gather the data you would like to use and design an appropriate database. Once you have the database ready, prepare some questions to help you analyze the data. Depending on the dataset, these questions may vary. You can use the following ones as a starting point:

  • How many people participated in the last tournament?
  • What was the win rate of the top players throughout the tournament?
  • What score was needed to get into the top 10?

Consider which metrics will be interesting to view after the tournament. Make sure that they don’t just show trivial information that can be gathered by the average viewer.

You can visualize the data with PowerBI to create post-game statistics graphics.

Resources

9. Job Application Tracker

Overview

Having a hard time keeping track of all the jobs you have applied for? Making a job application tracker can be a great idea for an SQL project. Not only will you be able to get a quick overview of your progress, but you’ll also be able to compile feedback from different recruiters and compare offers.

You can practice your SQL skills with this project on real world data. At the end of your job search, you will have a valuable database that may help you with any future job hunting.

Where to get the data

You can design your own simple database, storing the data that you find relevant to your job search – date applied, feedback from the recruiter, interview score, and so on. Every time you apply for a job or receive an update from the recruiter, update the database. It will fill up with data in no time!

Step-by-step instructions

Design a simple database that stores the most important information about each job application. You can tailor the size and complexity of the database to your future analysis goals.

Every time you apply to a position, make a new entry in the database. Edit entries as you progress through the application process or when you get feedback from the recruiter.

With some data, you should be able to use SQL to perform an analysis like this:

  • Which job applications don’t have a recruiter response (yet)?
  • How many companies have you sent applications to?
  • What was the feedback you received from all the Engineering positions (or other discipline) you’ve applied to in the last year?
  • How often do recruiters give feedback for each job area?
  • What is the average salary offer in each field?

Resources

10. Health Data Analysis

Overview

For this project, the range of potential data is quite wide. You can analyze the data about the spread of a specific disease in a specific region, or statistics about the recovery rate or spread of a particular illness. This SQL project is centered around creating reports from global real-world data, a great skill to practice and showcase in your portfolio.

Where to get the data

Kaggle has a great choice of datasets for a project like this. You can try keywords like “health”, the name of a specific disease, or a country that you are interested in. For example, you can try this extensive worldwide COVID-19 dataset, or a local dataset for the USA, India, or other countries.

Step-by-step instructions

Download a dataset that interests you and prepare a database for it. Import the dataset into the database and analyze the data using questions like the following:

  • What were the trends of the spread over every country/region?
  • How many people have been admitted to the hospital with this disease over the last month?
  • What were the hotspots in 2024?
  • What are the infection and recovery rates?

Optionally, you can visualize the data you have acquired using a map or tools like PowerBI.

Resources

SQL Code Project Examples and Further Practice

We have covered a lot of options with these 10 ideas for SQL code projects. You can always modify them to suit your needs or interests. Don’t forget to check out our collection of SQL practice databases; they are perfect for your first SQL project if you do not know where to start.

And if you would like to see an example of an SQL code example project from start to finish, take a look at our Sales Dashboard Project for the AdventureWorks database.

Happy coding!