Skip to content
wannacode

Databases and SQL

Almost every program keeps data: orders, users, messages, payments. This course is about where and how. You start from your first query against a real shop database and get to design, transactions, indexes, connecting from code, and the question of which database fits which job.

The queries run here, in the browser: every code field is a real SQLite database. You type, press “Run” and see the result. Nothing to install. At the end there is a module on the other kinds of databases (document, key-value, event streams, graphs, columnar, search, vectors), also with live simulators.

The course is split into modules, and each module into short lessons. A lesson is a series of cards, one idea per card: a question from real work, the query that answers it, and a small task you check right away. Your answer is compared with the correct result on the same database, and SQLite's error is explained in plain words.

Every module uses only what the earlier ones have shown. Your progress is kept in your browser.

Module 0

Welcome to databases

3 lessons · what a database is, tables, the first query

  1. Why a database
  2. The shop
  3. SQL and real databases

Module 1

Reading data

5 lessons · SELECT, WHERE, ORDER BY, LIMIT, NULL

  1. Only the columns you need
  2. Only the rows you need
  3. Lists, ranges and patterns
  4. NULL: no value
  5. Sorting, the first N, no repeats

Made by Ivo Gergov as part of Evo Tech's campaign for accessible programming education ·