Introduction to SQL
A free-tier-friendly, interactive introduction to SQL covering SELECT, WHERE, JOIN and GROUP BY, taught through in-browser coding exercises.
SQL is the single most commonly tested skill in data analyst interviews, and unlike many technical skills, it barely changes from job to job — a SQL query written for a retail company and one written for a healthcare company use the same core syntax. This roadmap covers the skill in the order that maps to real job requirements, not the order most tutorials happen to teach it in.
Everything else builds on this stage — don't rush it.
Recommended starting point: Introduction to SQL, which is free-tier-friendly and interactive.
Joins are where most interview screens actually separate candidates. Real business data lives across multiple tables, and combining them correctly is the daily reality of the job.
Practice target: given two tables (customers, orders), answer "which customers have never placed an order" — this requires a LEFT JOIN and a NULL check, and it's a genuinely common real-world and interview question.
This is where SQL moves from "filtering and combining" to "reasoning in steps."
WITH clause, which lets you name and reuse intermediate steps, making complex queries far more readable than deeply nested subqueriesSQL for Data Science (UC Davis) covers this stage well within a broader analysis-focused curriculum.
This is the stage that separates "knows SQL" from "is genuinely fluent in SQL," and it shows up constantly in intermediate-to-advanced interview questions.
Practice target: calculate month-over-month revenue growth per product category — this single problem exercises ranking, LAG, and often a CTE together.
Not every analyst role tests this deeply, but it matters increasingly as you work with larger tables, and it's a strong differentiator in interviews for more senior roles.
Once you're through stages 1–5, the remaining work is repetition against realistic problems, not new concepts. Rotate through practice platforms and real interview-style questions rather than continuing to consume new tutorial content — at this stage, fluency comes from doing, not watching.
See our 50 SQL interview questions for data analysts for a structured practice set organized by this same difficulty progression.
For someone with no prior SQL experience studying 5–7 hours a week, expect roughly 8–10 weeks to reach genuine interview-ready fluency through window functions. Query optimization can be learned more gradually alongside real work, since it matters less for junior screening than the earlier stages do.
Learning syntax without practicing on messy, realistic multi-table data. Tutorial exercises with one clean table teach the syntax but not the judgment — real practice means deliberately working with data that has duplicate rows, inconsistent NULLs, and tables that need three joins to answer one question.
Do I need to learn all of this before applying for jobs? No — stages 1–3 are enough to pass many entry-level screens. Window functions (stage 4) increasingly show up even at entry level, though, so don't skip it entirely.
Is SQL still relevant with all the AI coding tools available now? Yes — SQL fluency lets you verify and correct what an AI tool generates, which matters more, not less, as more of the boilerplate gets automated. See our piece on whether AI will replace data analysts for the fuller argument.
Should I learn SQL or Python first? SQL, for most people — see our SQL vs Python comparison for the full reasoning.
What's the best way to practice beyond a course? Rotate between structured practice platforms and real interview question sets, and periodically try to answer a business question using a multi-table dataset without looking up syntax first — that friction is where real fluency gets tested.
SQL rewards a specific, staged approach: fundamentals, joins, subqueries/CTEs, window functions, then optimization, with heavy practice on realistic multi-table data throughout. Most of the value sits in stages 1–4 — get those genuinely solid before worrying about advanced optimization, and you'll clear the large majority of analyst interview screens.
A free-tier-friendly, interactive introduction to SQL covering SELECT, WHERE, JOIN and GROUP BY, taught through in-browser coding exercises.
A UC Davis Coursera course teaching SQL specifically for data analysis workflows, covering querying, joining and aggregating real datasets.