Learn SQL for Data Engineering!!
Learn SQL for Data Engineering!!
Learn
In Just 10 Days
*Disclaimer*
This 10-day guide is structured to build your SQL
skills from the ground up, empowering you with
the knowledge to query and analyze data
efficiently.
www.bosscoderacademy.com 2
Day 1
SQL Basics
Overview of SQL
Understand what SQL is and why it's essential for Data
Engineering.
Basic Syntax
Learn SELECT statements, FROM clause, and how to execute
simple queries.
Practice Question
Write a query to select all columns from a customers
table
Write a query to select the name and email columns from
a users table
www.bosscoderacademy.com 3
Day 2
Filtering, Sorting, and
Operators
Filtering Data
Use the WHERE clause to filter datasets based on specific
criteria.
Sorting Results
Learn to use ORDER BY to sort your query results.
Operators
Dive into comparison and logical operators to refine your data
queries.
Practice Question
Write a query to select all records from an orders table
where the amount is greater than 100 and sort the results
by the order_date in descending order
Select all employees who work in the 'Marketing'
department and have been employed after January 1st,
2020. Order the results by employee_name.
www.bosscoderacademy.com 4
Day 3
Functions and Aggregations
SQL Functions
Explore built-in SQL functions like COUNT(), SUM(), AVG(), MIN(),
and MAX().
Grouping Data
Use GROUP BY to aggregate data and perform calculations on
groups.
HAVING Clause
Learn to filter aggregated data using the HAVING clause.
Practice Question
Find the average salary and total number of employees in
the employees table
Select the department and the highest salary in each
department from the employees table.
www.bosscoderacademy.com 5
Day 4
Joining Tables
Understanding Joins
Introduction to INNER JOIN, LEFT JOIN, RIGHT JOIN, and FULL
OUTER JOIN.
Aliasing
Use aliases to simplify your queries and improve readability.
Practice Question
Write a query to join orders table with customers table
on the customer ID and select the order ID, order date, and
customer name for all orders
Find all employees and their department names. Assume
you have employees and departments tables.
www.bosscoderacademy.com 6
Day 5
Subqueries and Nested
Queries
Introduction to Subqueries
Learn to write nested queries for complex data extraction.
Using Subqueries
Practice using subqueries in the SELECT, FROM, and WHERE
clauses.
Correlated Subqueries
Understand and apply correlated subqueries to perform more
advanced analysis.
Practice Question
Select all products that have a price above the average
price of all products. Use a subquery to determine the
average price
Write a query to find the names of employees who have
made more than 10 sales. Use a subquery to calculate the
number of sales per employee.
www.bosscoderacademy.com 7
Day 6
Set Operations
Set Theory Basics
Quick overview of set theory principles relevant to SQL.
Practice Question
Use UNION to combine the result sets of two queries: one
that selects all Python developers from an employees
table and another that selects all Data Scientists
Find employees who are both Python developers and Data
Scientists using INTERSECT.
www.bosscoderacademy.com 8
Day 7
Formatting Dates
Learn to format date and time values for better readability and
analysis.
Practice Question
Select all orders made in the last 30 days from the orders
table
www.bosscoderacademy.com 9
Day 8
Advanced SQL Features
Window Functions
Introduction to OVER(), PARTITION BY, and windowing functions
for advanced data analysis.
Practice Question
Use a window function to rank employees in each
department by their salaries
Write a query with a CTE that selects all employees who
have a salary above the average salary in their
department.
www.bosscoderacademy.com 10
Day 9
Indexes and Performance
Tuning
Understanding Indexes
Learn what indexes are and how they improve query
performance.
Creating Indexes
Practice creating and managing indexes on your tables.
Query Optimization
Tips and tricks for writing efficient SQL queries.
Practice Question
Assuming an orders table with columns order_id,
customer_id, and order_date, write a query to create an
index on order_date. (Note: Just the concept, syntax
might vary based on the SQL database.
Write a query to explain the execution plan of a select
statement that joins the employees table with the
departments table. (Note: Use your SQL database's
specific method to show the execution plan.)
www.bosscoderacademy.com 11
Day 10
Real-World SQL Project
Project Overview
Apply what you've learned on a real-world dataset.
Practice Question
Given a dataset of eCommerce transactions
(transactions table), write a query to find the top 3 most
purchased products
Using the customers table, write a query to find the
month-over-month growth rate in new customer sign-ups.
Compare the counts of new sign-ups each month to the
previous month.
www.bosscoderacademy.com 12
Resources and Practice:
Hands-on Practice
Sample Datasets
www.bosscoderacademy.com 13
Why
Bosscoder?
1000+ Alumni placed at Top
Product-based companies.
Explore More