SQL & Database Rounds

SQL Mock Interview

Window functions, query plans, schema design and indexing - practise the database round that appears in backend, data and analytics loops alike.

AI interviewer, unlimited reps Live one-on-one expert sessions Scored feedback, not just a transcript

The SQL round shows up in far more loops than its reputation suggests: backend, data engineering, analytics and increasingly product engineering. It is also the round where candidates most often plateau, because writing a query that returns the right rows is a much lower bar than the one being applied.

What is actually scored is whether you can reason about the plan. Two queries that return identical results can differ by orders of magnitude, and interviewers ask why. Expect questions about which index the predicate can use, why a function wrapped around a column disables it, when a hash join beats a nested loop, and what happens to the plan when the table grows a hundredfold.

Schema questions are access-pattern questions. Normalise or denormalise is not a style preference - the right answer follows from the reads you need to serve, the write volume, and the consistency you are willing to give up.

What the SQL Round Covers

Round 1

Query Writing

30-45 min

SQL

Joins, aggregation, window functions, deduplication with tie-breaking.

Round 2

Query Optimisation

30 min

SQL

Read a plan, find the bottleneck, choose an index, and justify the change.

Round 3

Schema Design

45 min

Design

Model a domain from its access patterns, choose keys, indexes and partitioning.

Round 4

Transactions & Concurrency

30 min

Theory

Isolation levels, the anomalies each allows, locking and deadlock handling.

SQL Topics to Drill

Window FunctionsCTEs & Recursive QueriesDeduplication PatternsGaps & IslandsJoin AlgorithmsIndex Selection & Covering IndexesCardinality & SelectivityQuery Plan ReadingNormalisation Trade-offsPartitioning StrategyIsolation Levels & AnomaliesDeadlocks & Lock Ordering

Frequently Asked Questions

Which SQL topics come up most often?

Window functions and deduplication are near-universal. After that: reasoning about a query plan and choosing an index, schema design driven by access patterns, and isolation levels with the specific anomaly each one permits.

How do I answer an optimisation question well?

Start from the plan, not from the query text. Identify the expensive operation, explain why the planner chose it, then propose a change - an index, a rewritten predicate, a different join order - and state what it costs on the write path.

Do backend interviews really include SQL?

Frequently, folded into the API and data modelling round rather than as a named SQL round. You will be asked to design the schema behind the feature you just designed, and then to explain how your main query stays fast as the table grows.

Sharpen the Database Round

Practise queries, plans and schema design under interview conditions.