courses / sql

learn sql

Three levels, from never written code to writing it like a professional. Ask questions of databases.

build things that are actually useful.

For people who finished Level 1, or can already write small programs with variables, decisions, loops and functions.

1 unit 1 Groups and totals Get one answer for every group, not one for the whole table. 0 of 4 · 35 min
  1. One answer per group8 min
  2. Sorting and sieving groups9 min
  3. Picking groups with HAVING9 min
  4. Groups inside groups9 min
2 unit 2 Join tables together Store each fact once, link tables by id, then bring them back together. 0 of 4 · 38 min
  1. Tables that point at each other9 min
  2. JOIN glues rows together10 min
  3. Short names for tables9 min
  4. Join, then group10 min
3 unit 3 More joins Keep rows with no match, find what is missing and join three tables. 0 of 4 · 38 min
  1. LEFT JOIN keeps everyone9 min
  2. Finding what is missing9 min
  3. Three tables at once10 min
  4. Counting zeros10 min
4 unit 4 Queries inside queries Check values against lists, and use one query's answer inside another. 0 of 4 · 36 min
  1. Is it in the list?8 min
  2. A query inside a query9 min
  3. IN with a subquery9 min
  4. A subquery as a column10 min
5 unit 5 Choose with CASE Make a query choose a value for every row, and fill in the blanks. 0 of 4 · 37 min
  1. CASE picks a value9 min
  2. First match wins9 min
  3. Counting with CASE10 min
  4. Filling the blanks9 min
6 unit 6 Rules that protect your data Let the database refuse bad data before it ever gets in. 0 of 4 · 35 min
  1. No two the same8 min
  2. A value when none is given8 min
  3. Checking values on the way in9 min
  4. Links that cannot break10 min
7 unit 7 Design and dates Link tables many to many, work with dates, then build a full report. 0 of 4 · 42 min
  1. Link tables10 min
  2. Dates are text in a set order10 min
  3. Counting days10 min
  4. Putting it all together12 min
end of level 2 level check Build one small project with everything from this level. Pass it and your face levels up. see the check