SQL Course: Learn SQL in 66 Interactive Lessons
By Owen Middleton · Updated October 2026 · We ran the examples on PostgreSQL 17
SQLMaxx Learn is a SQL course for beginners, with 66 lessons in order, from your first SELECT to funnel analysis and query debugging. You need no SQL experience. You write every query in a real PostgreSQL database that runs in your browser, and SQLMaxx Learn grades each answer. The course is free, and you do not need an account to start.
Try lesson 1 here
Lesson 1 is SELECT and Column Expressions. With a SELECT
statement, you pick columns from a table, and you can calculate a new column. The products table holds the items
of an online store. Run the query. Then change it.
Schema · ecommerce1 table? = nullable
SELECT name, price, price * 0.9 AS sale_price FROM products;
Write your first SQL query
How does SQLMaxx Learn work?
SQLMaxx Learn has two modes, Learn and Review.
- Learn: SQLMaxx Learn picks your next lesson from the lessons whose prerequisites you have mastered. You can read any lesson page at any time.
- Review: SQLMaxx Learn shows you earlier lessons again when it predicts that you will forget them soon. Review needs an account.
Each lesson has a mastery score, and SQLMaxx Learn updates it as you practice. To earn the certificate, you master all 66 lessons and solve at least one problem in each.
Which SQL topics does SQLMaxx Learn cover?
SQLMaxx Learn has 66 lessons in 5 tiers and 615 practice problems. It starts with SELECT and Column Expressions (lesson 1) and ends with Analyst Debugging Patterns (lesson 66). The lessons include joins, CTEs, window functions, and analyst topics such as funnel analysis. Each lesson has its own page with the full lesson and its problems.
To use the first lessons in a game, play the SQL Murder Mystery, a free detective case. In our SQL Murder Mystery solution, each step names the lesson for its SQL.
Tier 1 · Foundations
12 lessons- 1 SELECT and Column Expressions
- 2 FROM and Table References
- 3 WHERE Clause and Comparison Operators
- 4 Literal Values, Data Types, and Type Casting
- 5 NULL Semantics and IS NULL
- 6 Boolean Logic in WHERE (AND, OR, NOT)
- 7 ORDER BY and Result Sorting
- 8 LIMIT and OFFSET
- 9 Column Aliases and Expression Naming
- 10 DISTINCT
- 11 Arithmetic and Comparison Expressions
- 12 BETWEEN, IN, and LIKE
Tier 2 · Core SQL
15 lessons- 13 Aggregate Functions (COUNT, SUM, AVG, MIN, MAX)
- 14 GROUP BY
- 15 HAVING
- 16 CASE WHEN Expressions
- 17 INNER JOIN
- 18 LEFT JOIN and RIGHT JOIN
- 19 FULL OUTER JOIN
- 20 CROSS JOIN
- 21 Self-Joins
- 22 Joining Multiple Tables
- 23 UNION, UNION ALL, INTERSECT, EXCEPT
- 24 Scalar Subqueries
- 25 Subqueries in WHERE (IN, EXISTS, ANY, ALL)
- 26 Derived Tables (Subqueries in FROM)
- 27 Conditional Aggregation (CASE inside Aggregates)
Tier 3 · Intermediate
14 lessons- 28 COALESCE and NULLIF
- 29 NULL Handling in Joins and Aggregates
- 30 Common Table Expressions (CTEs)
- 31 Chained CTEs
- 32 Date and Time Types in PostgreSQL
- 33 Date Truncation and Extraction
- 34 Date Arithmetic and Intervals
- 35 String Functions (LENGTH, UPPER, LOWER, TRIM, SUBSTRING)
- 36 String Concatenation and Formatting
- 37 Pattern Matching (LIKE, ILIKE, SIMILAR TO, Regex)
- 38 Window Functions Introduction (OVER, PARTITION BY)
- 39 ROW_NUMBER, RANK, DENSE_RANK
- 40 Aggregate Window Functions (SUM, AVG, COUNT OVER)
- 41 Temp Tables and CREATE TABLE AS SELECT
Tier 4 · Advanced
16 lessons- 42 LAG and LEAD
- 43 FIRST_VALUE, LAST_VALUE, NTH_VALUE
- 44 Window Frames (ROWS, RANGE, GROUPS)
- 45 NTILE and Percentile Functions
- 46 DISTINCT ON
- 47 Correlated Subqueries
- 48 LATERAL Joins
- 49 FILTER Clause on Aggregates
- 50 STRING_AGG and ARRAY_AGG
- 51 generate_series() for Sequences and Date Spines
- 52 Recursive CTEs
- 53 JSONB Field Extraction
- 54 JSONB Aggregation (jsonb_agg, json_build_object)
- 55 Date Spine Construction and Zero-Fill Patterns
- 56 Period-over-Period Analysis
- 57 Grouping by Date Periods
Tier 5 · Expert
9 lessons- 58 Multi-CTE Query Architecture
- 59 Join Fanout and Aggregate Correctness
- 60 Reading EXPLAIN Output
- 61 Query Structure Patterns for Performance
- 62 Choosing Between Subqueries, CTEs, and Joins
- 63 NULL Propagation in Complex Queries
- 64 Running Totals and Cumulative Metrics
- 65 Sessionization and Funnel Analysis Patterns
- 66 Analyst Debugging Patterns
Does SQLMaxx Learn give a certificate?
Yes. SQLMaxx Learn gives you the SQLMaxx Certificate of Completion. One certificate, awarded when you have mastered all 66 lessons in the curriculum and solved at least one problem in each. Mastery is measured by the engine as you practice, against a live PostgreSQL database. There is no exam and no fee. A certificate needs an account.
SQLMaxx is not an accredited body and this is not a professional license. No certificate from anyone gets you a job on its own. It records what you did, on the date shown, under the conditions described.
Every certificate has a public page at sqlmaxx.com/verify/ followed by its ID. It shows who holds it, when it was issued, and whether it is still valid. No account is needed to open it, and the QR code on the document goes to the same place.
Read more about it: SQL Course With Certificate: How the SQLMaxx Learn Certificate Works.
Compare SQL courses and plan your next step
SQL guides to use with SQLMaxx Learn
In each guide, we answer one PostgreSQL question in more detail than in the lessons. Next to each guide, you see the number of the course lesson on the same topic.
Write PostgreSQL date code in place of DATEDIFF, DATEADD and GETDATE. Find the date bugs that give a wrong answer with no error.
- What replaces DATEDIFF in PostgreSQL? Lesson 32
- What replaces DATEADD in PostgreSQL? Lesson 32
- What is GETDATE() in PostgreSQL? Lesson 32
- How do you convert a string to a date in PostgreSQL? Lesson 4
- How do you format a date in PostgreSQL? Lesson 33
Put rows into a list, a JSON document or a pivot. Learn what happens to the answer when a column has nulls.
- What replaces GROUP_CONCAT in PostgreSQL? Lesson 13
- How do you sort the values inside STRING_AGG? Lesson 50
- How do you return JSON from a PostgreSQL query? Lesson 53
- How do you pivot rows into columns in PostgreSQL? Lesson 14
- Why does json_agg return null instead of an empty array? Lesson 28
- Which rows do SQL aggregate functions skip? Lesson 13
How OVER, PARTITION BY and the window functions actually behave.
- Is OVER a function in SQL? Lesson 38
Questions about SQLMaxx Learn
Is SQL still worth learning in 2026?
Yes. In the 2026 Stack Overflow Developer Survey, 58.4% of the developers who answered did extensive development work in SQL over the past year. Only JavaScript had a larger share, at 62.0%. Source: Stack Overflow Developer Survey 2026, Technology. Read more about whether SQL is still relevant.
Can SQL be self-taught?
Yes. You can learn SQL on your own with SQLMaxx Learn. SQLMaxx Learn grades each answer, so you do not need a teacher to check your work.
Do you need an account to use SQLMaxx Learn?
No. You can start lesson 1 of SQLMaxx Learn without an account, and SQLMaxx Learn saves your progress in this browser. With an account, you can use Review and earn the certificate. When you sign up, SQLMaxx Learn moves your progress to your account.
Which SQL dialect does SQLMaxx Learn teach?
PostgreSQL 17. PostgreSQL runs every query in your browser, so you have nothing to install. SQLMaxx Learn does not teach the MySQL or SQL Server dialects.
How much does SQLMaxx Learn cost?
Nothing. All 66 lessons, all 615 practice problems and the certificate are free.
What does SQLMaxx Learn not include?
SQLMaxx Learn has no video lessons and no instructor. You learn from written lessons, examples that you run, and graded problems. Without an account, you can continue only in the browser where you started.