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
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
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
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
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
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
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:
| Stage | Time | What you learn |
|---|---|---|
| Foundations and basic queries (phases 1-3) | 2-3 weeks | Install a database, learn tables and keys, and write SELECT, WHERE, ORDER BY and NULL-safe filters. |
| Functions and aggregation (phases 4-5) | 2 weeks | String, date and CASE expressions, aggregate functions, GROUP BY, HAVING and ROLLUP. |
| Joins, subqueries and CTEs (phases 6-7) | 2-3 weeks | Every join type, anti joins, fan-out mistakes, subqueries, EXISTS, CTEs and set operations. |
| Window functions (phase 8) | 1-2 weeks | ROW_NUMBER, RANK, LAG and LEAD, running totals, window frames and top-N per group. |
| Changing data and schema design (phases 9-10) | 2 weeks | INSERT, UPDATE, DELETE and upserts, CREATE TABLE, constraints, ER diagrams and normalization. |
| Performance, transactions and security (phases 11-13) | 2-3 weeks | Indexes and EXPLAIN, transactions, isolation levels and locking, views, procedures, triggers and permissions. |
| Analysis projects and interview prep (phases 14-15) | 2-4 weeks | Cleaning, 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:
- Set Up a Database and Load Sample DataPhase 1
- Write 20 SQL Queries Against a Sample DatabasePhase 2
- Monthly Sales Summary ReportPhase 5
- E-commerce Sales Analysis Case StudyPhase 6
- Customer Segmentation with CTEsPhase 7
- Top-N Products per Category ReportPhase 8
- Month-over-Month Revenue Growth AnalysisPhase 8
- Design a College Management DatabasePhase 10
- Speed Up a Slow Report QueryPhase 11
- Bank Transfer SimulationPhase 12
- Product Analytics Case StudyPhase 14
- End-to-End SQL + BI Dashboard ProjectPhase 14
- 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.
