roadmap
- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
Write and reason about SQL the way interviews test it, from joins and window functions to how the engine runs your query. Covers querying, schema and constraints, indexes, transactions, and safe queries.
932 of 932 questions in your plan: 0 known, 0 in progress, 0 due, 0 skipped, 932 new. 0 cut, outside your plan.
SQL turns up in two kinds of loop. Data analyst, data engineer and data scientist loops usually give it a round of its own: a schema on a shared screen, a business question, and a query written while the interviewer watches. Backend loops more often bring it into the technical or design conversation, as a schema to sketch, an index to choose or a slow endpoint to explain.
The writing round is graded on edge cases more than syntax: a NOT IN against a subquery that returns a single NULL empties the result, and a condition on the right-hand table written in WHERE instead of ON quietly turns a LEFT JOIN into an inner one. The backend conversation goes beneath the query: why an index on (customer_id, created_at) serves a filter on the customer far better than one on the date alone, and what two sessions that each read a balance and write it back can lose under the isolation level most engines default to.
Getting the rows right is the junior bar. For a senior candidate the query is taken for granted, and the follow-ups turn to what it promises: whether a report sees a consistent snapshot while writes continue, whether a uniqueness rule belongs in a constraint or in application code that two concurrent requests can both pass.
The plan splits between what you write and what the engine does with it. The SQL hub opens Query Language with the single-table query, where three-valued logic first bites, and runs through joins and grouping to nested queries and writes; its performance section stays on the author's side, asking how a predicate must be spelled for an index to help. Window functions close the hub, since filtering on a rank usually means wrapping the query that computes it. SQL injection ends the module: a query assembled by string concatenation is one its input can rewrite.
Database Behavior first asks whether a relational store is the right choice at all, which is datastore selection, then goes beneath the language. The relational model explains what the first module taught as rules: its relations are sets while SQL tables keep duplicates, and a comparison with NULL yields a third truth value. Schema design and the constraints that let the engine refuse bad data come next, with views, procedures and triggers as the code a schema can carry.
The turn to the engine comes with indexes and access paths, which give the first module's spelling advice its reasons. Transactions follow: MVCC decides which row versions a session sees, locking decides who waits. Access control picks up the thread injection started, since a least-privilege application account limits what an injected statement can reach. Query processing is last on purpose: a plan is written in the vocabulary of everything above it, and it is where a senior answer to "why is this slow" ends up.
For a data analyst or data engineer screen, the written query is the round, and the first module deserves most of the hours. A week or so out, let importance keep only must know, which shrinks Database Behavior to what a SQL round borrows from it, and run each answer in a scratch database against a table with a NULL planted in the column it filters on. Backend engineers have the reverse problem: the queries come easily and the follow-ups land in indexes, isolation and plans. A couple of months out, the second module is worth taking in the sequence its arguments build in, which means study order on by topics; check each index answer with `EXPLAIN` on a PostgreSQL table large enough for the planner to choose. The plan is engine-neutral, and no topic in it covers keeping a database running: backups, replication, failover, recovery. If the posting names an engine, the [PostgreSQL roadmap](/roadmaps/postgresql) carries much of this plan onto one product, and the [PostgreSQL DBA roadmap](/roadmaps/postgresql-dba) is where keeping that engine alive is the subject.
For a data analyst or data engineer screen, the written query is the round, and the first module deserves most of the hours. A week or so out, let importance keep only must know, which shrinks Database Behavior to what a SQL round borrows from it, and run each answer in a scratch database against a table with a NULL planted in the column it filters on. Backend engineers have the reverse problem: the queries come easily and the follow-ups land in indexes, isolation and plans. A couple of months out, the second module is worth taking in the sequence its arguments build in, which means study order on by topics; check each index answer with EXPLAIN on a PostgreSQL table large enough for the planner to choose.
The plan is engine-neutral, and no topic in it covers keeping a database running: backups, replication, failover, recovery. If the posting names an engine, the PostgreSQL roadmap carries much of this plan onto one product, and the PostgreSQL DBA roadmap is where keeping that engine alive is the subject.