1. SELECT & Filtering
  2. Joins & GROUP BY
  3. CTEs & Window Functions
  4. Design, Performance & Interview-ready

SQL Roadmap

A complete, step-by-step path to learning SQL from zero: relational database basics, SELECT and filtering, functions, GROUP BY, joins, subqueries and CTEs, window functions, data changes, schema design, indexes and performance, transactions, views and security, ending with real analysis projects and interview prep.

15

Stops

137+

Topics

13

Projects

3-5 months

Est. time

Your ticket

0%

0 / 150

stops cleared

Stuck on a topic? Ask an Insider

Get 1:1 guidance from people who've walked this exact path — on the InsideEdge app.

Download

About the SQL Roadmap

SQL (Structured Query Language) is the standard language for storing, reading and changing data in relational databases like MySQL, PostgreSQL and SQL Server. Analysts use it to answer business questions, developers use it to power applications, and data engineers use it to build pipelines.

This SQL roadmap is for college students and early-career learners in India who want to move into data analyst, business analyst or other data roles. Across 15 phases it starts from what a table is and builds up to joins, CTEs, window functions, schema design, indexes, transactions and security, then finishes with real analysis projects and interview practice.

Each phase lists the exact topics to learn and the projects to build. Tick items off as you go and your progress is saved in your browser.

How to learn SQL from scratch

  1. 1

    Install a database and load sample data

    Install MySQL or PostgreSQL with a client like MySQL Workbench, pgAdmin or DBeaver, then load a sample database. Learning on real tables from day one makes every concept stick faster.

  2. 2

    Master SELECT, filtering and functions

    Learn SELECT, WHERE, ORDER BY, LIMIT, NULL handling, string and date functions and CASE WHEN. Write a few queries every day that answer simple questions about one table.

  3. 3

    Learn GROUP BY and joins thoroughly

    Practise aggregates, GROUP BY and HAVING, then every join type. Pay special attention to LEFT JOIN vs INNER JOIN and duplicate rows from joins, since these cause most real-world mistakes.

  4. 4

    Move on to CTEs and window functions

    Use subqueries and CTEs to break big problems into steps, then learn ROW_NUMBER, RANK, LAG, LEAD and running totals. These are what separate intermediate SQL from beginner SQL in interviews.

  5. 5

    Understand design, performance and transactions

    Design normalized tables with keys and constraints, use indexes and EXPLAIN to make slow queries fast, and change data safely inside transactions that hold up when many users write at once.

  6. 6

    Build analysis projects and practise interview problems

    Complete 2-3 projects on public datasets, such as funnel, cohort or sales analysis, and publish them on GitHub. Solve SQL problems on practice platforms regularly and explain your answers out loud.

How long does the SQL roadmap take?

About 3-5 months studying part-time. A typical pace:

StageTimeWhat you learn
Foundations and basic queries (phases 1-3)2-3 weeksInstall a database, learn tables and keys, and write SELECT, WHERE, ORDER BY and NULL-safe filters.
Functions and aggregation (phases 4-5)2 weeksString, date and CASE expressions, aggregate functions, GROUP BY, HAVING and ROLLUP.
Joins, subqueries and CTEs (phases 6-7)2-3 weeksEvery join type, anti joins, fan-out mistakes, subqueries, EXISTS, CTEs and set operations.
Window functions (phase 8)1-2 weeksROW_NUMBER, RANK, LAG and LEAD, running totals, window frames and top-N per group.
Changing data and schema design (phases 9-10)2 weeksINSERT, UPDATE, DELETE and upserts, CREATE TABLE, constraints, ER diagrams and normalization.
Performance, transactions and security (phases 11-13)2-3 weeksIndexes and EXPLAIN, transactions, isolation levels and locking, views, procedures, triggers and permissions.
Analysis projects and interview prep (phases 14-15)2-4 weeksCleaning, funnel and cohort analysis, a GitHub portfolio project and daily interview-style practice.

Skills checklist

  • Write SELECT queries with WHERE, ORDER BY and LIMIT
  • Handle NULLs correctly with IS NULL and COALESCE
  • Use string, date and CASE WHEN expressions
  • Summarize data with GROUP BY and HAVING
  • Combine tables with INNER, LEFT and FULL OUTER joins
  • Spot and fix duplicate rows caused by joins
  • Break complex problems into CTEs and subqueries
  • Write window functions like ROW_NUMBER, RANK, LAG and running totals
  • Design normalized tables with primary and foreign keys
  • Insert, update and delete data safely inside transactions
  • Speed up queries with indexes and EXPLAIN
  • Explain isolation levels, locking and deadlocks
  • Create views, stored procedures and least-privilege roles
  • Run funnel, cohort and year-over-year analyses in SQL

Get the whole roadmap and this checklist as a free PDF.

SQLprojects you’ll build

13 hands-on projects, from beginner to portfolio-ready, each with its own step-by-step guide:

  1. Set Up a Database and Load Sample DataPhase 1
  2. Write 20 SQL Queries Against a Sample DatabasePhase 2
  3. Monthly Sales Summary ReportPhase 5
  4. E-commerce Sales Analysis Case StudyPhase 6
  5. Customer Segmentation with CTEsPhase 7
  6. Top-N Products per Category ReportPhase 8
  7. Month-over-Month Revenue Growth AnalysisPhase 8
  8. Design a College Management DatabasePhase 10
  9. Speed Up a Slow Report QueryPhase 11
  10. Bank Transfer SimulationPhase 12
  11. Product Analytics Case StudyPhase 14
  12. End-to-End SQL + BI Dashboard ProjectPhase 14
  13. SQL Portfolio Project on GitHubPhase 15

Jobs this roadmap leads to

Data Analyst

Writes SQL to pull and analyse data, then shares findings through reports and dashboards.

Business Analyst

Uses SQL to check numbers and answer business questions while working with stakeholders on requirements.

MIS / Reporting Analyst

Builds and maintains regular reports for management, often from SQL queries feeding Excel or BI tools.

Junior Data Engineer

Uses SQL to build and test the tables and pipelines that analysts and dashboards depend on.

Backend Developer

Designs database tables and writes queries that power application features.

Free crash courses for the basics

Short video lessons with notes, from university syllabi.

Frequently asked questions

Everything about the SQL roadmap.

Most beginners can write useful SELECT, WHERE, GROUP BY and JOIN queries within 3-4 weeks of regular practice. Completing all 15 phases of this roadmap, including window functions, schema design, indexes, transactions and projects, usually takes 3-5 months studying part-time (8-10 hours a week), or about 2 months full-time.

SQL on its own is rarely enough, but it is one of the most requested skills for data analyst, business analyst and backend roles. For analyst jobs, pair it with Excel and one BI tool such as Power BI or Tableau, plus 2-3 portfolio projects. For developer or data engineering roles, pair it with a programming language like Python or Java.

Start with SELECT, filtering with WHERE and NULL handling, then functions and CASE, then GROUP BY and HAVING, then joins. Once joins feel easy, move to subqueries and CTEs, then window functions (phases 1-8). Changing data, schema design, indexes, transactions and views come after (phases 9-13), because they make more sense once you have written plenty of queries. Finish with analysis projects and interview practice (phases 14-15).

Either is fine because the core SQL is almost the same and skills transfer easily. MySQL is very common in web applications and many Indian college courses, while PostgreSQL follows the SQL standard more closely and has richer features for analysis. Pick one, learn it well, and check which one appears in the job posts you are targeting.

Build 2-3 projects on real public datasets: an e-commerce sales analysis using joins and GROUP BY, a window function project like top products per category or month-over-month growth, and one end-to-end case study such as funnel or cohort retention analysis. Put the queries on GitHub with a README that states each business question and the answer you found.

Certifications are optional for SQL, and recruiters usually care more about projects and a SQL test. If you want one, the HackerRank SQL skill certificates are free and quick, and Oracle's Database SQL Certified Associate (exam 1Z0-071) is a recognised vendor certification. Microsoft's PL-300 is a Power BI certification, not a SQL one, but it is useful if you plan to become an analyst.

InsideEdge