Become a data analyst in 90 days✦27 portfolio projects✦100+ interview Q&As✦1:1 mentor for a year✦See the 90-Day System →✦Become a data analyst in 90 days✦27 portfolio projects✦100+ interview Q&As✦1:1 mentor for a year✦See the 90-Day System →✦
New here? Want every day planned for you? See the 90-Day System →

Free PDF · SQL

SQL in 30 days. This order.

What to learn, in what order, and what to practise each week. From SELECT to window functions to interview mode.

DGSQLSQL in 30 daysweek by week@thedataguy16

SQL in 30 days. One topic at a time.

Weeks 1-2: SELECT, WHERE, GROUP BY. Week 3: JOINs and CTEs. Week 4: window functions, then interview mode.

One hour a day. 20 minutes learning, 30 minutes solving, 10 minutes redoing what you got wrong.

Don't jump between courses. Pick one and finish it.

Save this and start Day 1 tonight.

Weeks 1-2: the basics

DAY 1-7

Read data

  • SELECT, WHERE, ORDER BY, LIMIT
  • AND / OR, IN, BETWEEN, LIKE
  • IS NULL and COALESCE
  • 20 easy problems
DAY 8-14

Summarise

  • COUNT, SUM, AVG, MIN, MAX
  • GROUP BY + HAVING
  • CASE WHEN for buckets
  • 25 problems

Week 3: combine tables

DAY 15-18

JOINs

  • INNER, LEFT and self joins
  • Rows with no match: LEFT JOIN + IS NULL
  • UNION vs UNION ALL
DAY 19-22

Subqueries + CTEs

  • Subquery inside WHERE
  • WITH ... AS (CTE)
  • Split one hard question into 2-3 steps

Week 4: what interviews test

DAY 23-26

Window functions

  • ROW_NUMBER, RANK, DENSE_RANK
  • LAG / LEAD for change vs last month
  • Running total with SUM() OVER
DAY 27-30

Interview mode

  • 2 medium problems a day, 20 min each
  • Explain every query out loud
  • 1 project on a real sales dataset
Free Practise every week of this plan on real tables. Open the SQL playground →

The query you'll write again and again

top_3_per_category.sql

WITH ranked AS (
  SELECT category, product, sales,
         DENSE_RANK() OVER (
           PARTITION BY category
           ORDER BY sales DESC) AS rnk
  FROM product_sales
)
SELECT category, product, sales
FROM ranked
WHERE rnk <= 3;

Top N per group. Once you can write this without notes, week 4 is done.

Your daily hour

BlockTimeDo
Learn20 minOne concept
Practise30 min3-5 problems
Review10 minRedo one wrong answer

Practice gets the most time. Reading is not learning.

Rules for 30 days

Don't

  • Jump between 5 courses
  • Copy the solution
  • Wait for a free weekend

Do

  • One resource, start to end
  • Type every query yourself
  • 1 hour, every single day

Free PDF

SQL in 30 days: week-by-week plan

Download the PDF

Opens in Google Drive. No sign-up.

Keep going

More free PDFs

90-Day System · become a data analyst→