SQL Interview Readiness Checklist for Data Analysts
A syntax list cannot tell you whether you are ready for a live SQL interview. This checklist tests the decisions interviewers can hear: output grain, join behavior, tie rules, time boundaries, edge cases, and whether you can explain a correct query under pressure.
Print this page or save it as a PDF from your browser to keep the checklist beside you.
How to use this checklist
- Diagnose: mark a skill only when you can meet the evidence statement without notes or AI.
- Practice: use the linked problem set for every unchecked skill.
- Prove: finish the seven-day plan with a timed mock and a written repair note.
The eight-part readiness scorecard
Do not score familiarity. Score observable performance: what you can predict, write, test, and explain.
| Skill | You are ready when | Failure to catch |
|---|---|---|
| Output grain | You can state what one result row represents before writing SQL. | Correct syntax that returns duplicate or over-aggregated rows. |
| JOINs and fanout | You can predict unmatched rows and row multiplication before joining. | Aggregates become inflated after a one-to-many join. |
| GROUP BY and HAVING | You can separate row filters from group filters and preserve the requested grain. | Using WHERE for an aggregate condition or grouping by unnecessary columns. |
| Window functions | You can choose partition, order, frame, and tie behavior deliberately. | Using a ranking function without defining what should happen at a tie. |
| Conditional logic | You can write mutually exclusive CASE branches and conditional aggregates. | Overlapping conditions or an omitted ELSE silently misclassify rows. |
| Date logic | You can define inclusive and exclusive boundaries and handle missing periods. | A timestamp on the final day falls outside an inclusive-looking date filter. |
| NULL behavior | You can explain how NULL changes comparisons, counts, joins, and arithmetic. | NOT IN, equality checks, or arithmetic produce an unexpected unknown result. |
| Verification and explanation | You test edge cases and can explain every stage without reading the query line by line. | A plausible result is accepted without checking duplicates, ties, or missing values. |
Interpret your score
0-3 checked: rebuild fundamentals before timed practice. 4-6: practice the missing patterns deliberately. 7-8: move to timed mocks and explanation quality.
The decision sheet
Translate the wording of the problem into a query shape before choosing syntax. This prevents the most expensive interview mistake: solving the wrong grain cleanly.
| When the prompt asks for | Start with | Check before submitting |
|---|---|---|
| One row per group | GROUP BY | Every selected non-aggregate must match the output grain. |
| Keep detail rows and add a metric | Window aggregate | GROUP BY would collapse the detail rows. |
| Exactly N rows per group | ROW_NUMBER | Add deterministic tie-breakers to the window order. |
| Keep all ties at the cutoff | RANK or DENSE_RANK | Clarify whether skipped rank numbers matter. |
| Compare with an earlier row | LAG | Confirm the sequence and whether periods can be missing. |
| Find rows without a match | NOT EXISTS or LEFT JOIN | Avoid NOT IN when the subquery can contain NULL. |
| Filter an aggregate | HAVING | WHERE runs before grouping and cannot filter a group result. |
| Filter a timestamp range | Half-open interval | Use start inclusive and next boundary exclusive. |
The 60-second pre-query check
1. Define the result
What does one output row represent? Which columns are identifiers, dimensions, or metrics?
2. Inspect relationships
Are join keys unique? Which unmatched rows must remain? Can a join multiply a value before aggregation?
3. Place each operation
Which filters happen before grouping? Do you need collapsed groups or detail rows with an added window metric?
4. Name the edge cases
Test one duplicate, one NULL, one tie, one missing period, and the smallest valid input that changes the result.
A seven-day SQL interview practice plan
Each day ends with evidence, not a reading target. If the evidence is weak, repeat the day with a different question before moving on.
Day 1: Baseline and query grain
Take the readiness diagnostic, then solve two Easy aggregation questions without AI.
Evidence to produce: Write a one-sentence output-grain definition before each query and verify the row count.
Open day 1 practiceDay 2: JOINs, missing rows, and fanout
Practice INNER, LEFT, and anti-join problems using edge cases with duplicate keys.
Evidence to produce: Predict the joined row count before execution and explain why an aggregate will or will not inflate.
Open day 2 practiceDay 3: Aggregation and conditional metrics
Solve GROUP BY, HAVING, and conditional aggregation questions at two difficulty levels.
Evidence to produce: Separate row filtering from group filtering and produce the requested grain without extra grouping columns.
Open day 3 practiceDay 4: Window functions and ties
Practice latest-row, ranking, running-total, and period-comparison patterns.
Evidence to produce: Choose ROW_NUMBER, RANK, or DENSE_RANK from the business rule and state the tie policy aloud.
Open day 4 practiceDay 5: Dates, CASE, and NULLs
Solve one date-boundary problem and one classification problem, then add a NULL edge case.
Evidence to produce: Use explicit time boundaries, mutually exclusive CASE branches, and deliberate NULL handling.
Open day 5 practiceDay 6: Timed business case
Complete the SaaS conversion-drop case without looking at a worked solution.
Evidence to produce: Translate an ambiguous business question into metrics, SQL stages, checks, and a concise recommendation.
Open day 6 practiceDay 7: Mock interview and repair loop
Solve one Medium question in 25 minutes while explaining your approach, then review the recording or notes.
Evidence to produce: Identify one reasoning weakness, repeat that pattern, and explain the corrected query in under two minutes.
Open day 7 practiceThe final mock-interview gate
You are ready to schedule a SQL interview when you can complete all five checks in one session:
- Clarify the requested grain and assumptions before coding.
- Produce a correct first query or identify the defect through a deliberate test.
- Explain join cardinality, NULL behavior, ties, and time boundaries where relevant.
- Use deterministic ordering when the result or row selection depends on order.
- Summarize the business answer without narrating SQL syntax line by line.
Turn the checklist into evidence
Choose a real interview-style problem, write the query in your browser, and use the result to mark the first honest checkbox.