How-toData QualityDoneStarted
Find and remove duplicate rows in SQL
Count the copies, number them with ROW_NUMBER, delete all but one per group, and add a unique index so they cannot come back.

From removing duplicates and window functions to modelling for reporting, cohort analysis, indexes and query plans: the SQL a working analyst or engineer uses every week, each lesson with queries that were run.
Outcomes
Explain what an index is and how it speeds up a lookup
Say what each of the four ACID properties guarantees
Choose the column order of a composite index
Use a transaction so a multi-step change succeeds or fails as one
Recognise queries that cannot use an index
Know what isolation levels trade off
Covered
Learning plan
Each lesson is short enough for one sitting and ends by pointing to the next.
How-toData QualityDoneStarted
Count the copies, number them with ROW_NUMBER, delete all but one per group, and add a unique index so they cannot come back.
ReferencePython & SQLDoneStarted
The window functions you will use every week (ranking, running totals, previous row, share of total), each with a short query and the result it returns.
TutorialData ModelingDoneStarted
Turn a flat sales export into one fact table and three dimensions, decide the grain, and answer questions with a single join pattern.
TutorialCohort AnalysisDoneStarted
Group users by the month they first appeared, count how many return in each later month, and read the result as a retention table.
ExplainerIndexingDoneStarted
What an index is, what it costs, how to read the difference between a scan and a search, and the four reasons a query ignores the index you made.
How-toQuery OptimizationDoneStarted
Ask the database how it will run a query, read the plan from the inside out, and use it to decide whether an index, a rewrite or nothing at all is the fix.
ExplainerRelationalDoneStarted
What atomicity, consistency, isolation and durability promise, shown with a money transfer that fails half-way and leaves nothing behind.
TroubleshootingRelationalDoneStarted
Why SQLite refuses a second writer, how to reproduce the error in six lines, and the changes (shorter transactions, a timeout, WAL mode) that stop it.
Questions