Data & spreadsheets · course 38 of 105
SQL Interviews: The Hard Parts
Handle what SQL interviews ask once the basics are in: window functions and ties, running totals, classics like top N per group and gaps and islands, and the NULL traps.
Not on sale yet. When sales open: $4.99 USD for this course, paid once, or every course for $9.99 USD a month. Prices
$4.99 USD, paid once. Or every course for $9.99 USD a month until you cancel; try it free for 7 days first (email only, no card, ends on its own). Tax added at checkout where it applies.
Runs in Claude (claude.ai, the Claude apps or Claude Code) with your own Claude account. A course opens there as soon as your payment goes through; nothing is shipped.
Preview
What it teaches
The SQL that interviews lean on once the basics are in: window functions (ROW_NUMBER vs RANK vs DENSE_RANK with ties, PARTITION BY, LAG and LEAD, running totals and how ties change them, moving averages with a ROWS frame), the classic problems (second highest salary, top N per group with ties, paid more than their manager, login streaks with gaps and islands, departments with no one), and the NULL traps (COUNT(*) vs COUNT(col), AVG skipping NULLs, NOT IN meeting a NULL, = NULL, a LEFT JOIN undone by WHERE, SUM of nothing). The AI asks 3 questions, places you, shows a short rule card per module, then gives you one item at a time: say what a query returns, or write the query, graded on its result rows against 4 small tables.
Analysts and engineers preparing for a SQL interview or screen who already write SELECT, GROUP BY and JOIN.
How long
39 items in the banks (30 + 9 concept). Roughly 25-50 rounds plus a 12-item final: 2-3 sessions (not timed with a real student). The tutor gives a one-line save code at the end of each session.
The modules
3 modules, drilled one item at a time.
- M1
Window functions
Say what a query returns, write the query, or answer a concept question
- M2
Classic interview problems
Say what a query returns, write the query, or answer a concept question
- M3
NULLs and aggregate traps
Say what a query returns, write the query, or answer a concept question
Before it teaches, it asks
- 1What is this for (a data analyst or engineer interview, a promotion, practice)? Which database do you use or expect (Postgres, MySQL, SQL Server, BigQuery, Snowflake, SQLite, no idea)? Can you run queries somewhere right now?
- 2What does this return?
- 3Return the second highest different salary in the whole company as one column called second.
What’s exact, and what isn’t
Show
Straight from the course’s own notes.
- Exact
- Every query answer key, expected table, “also right” query and trap result was produced by running the query on SQLite 3.53.0 and again on SQLite 3.43.2, with no difference. All 30 hand-written expected results matched. Every listed wrong answer is checked to differ from the key, and 11 of the 20 wrong answers on the read-the-query items are also run as the mistaken query that produces them. A planted-error test (4 errors) was caught.
- Sourced
- The teach-card rules quote the SQLite documentation (short quotes, matched on the pages on 2026-10-10).
- Dialects
- Keys run on SQLite; the same logic in Postgres, MySQL, SQL Server, BigQuery or Snowflake is graded right, unless a dialect difference changes the rows returned. Where NULLs sort differs by database (SQLite and MySQL first in ascending order, Postgres last); the tutor names it when it matters.
- Not in it yet
- Recursive CTEs, pivots, date functions, query plans and performance.