SQL Practice Drills

About SQL Practice Drills

Schema plus question, pick the correct query. JOINs, window functions, aggregation, and the NULL traps that break naive answers.

Each drill gives you the DDL and the question, then four queries that all look plausible. Usually exactly one handles NULLs, ties, or duplicate rows correctly, the explanation walks through the rows where the others diverge. Cards are drawn with spaced repetition, so the ones you miss come back sooner and the ones you know back off. Progress is kept in your browser.

SQL topics covered · 14