01Chapter 1: The example schema and the constraints that guard itThis chapter sets up the two tables used in the rest of the tutorial and shows how to add rows to them. Constraints decide which rows the database accepts, so you need to understand them before you change any data.2 min read
02Chapter 2: Changing rows with UPDATEThis chapter assumes you know basic SELECT with WHERE, the orders table from the example schema (columns id, customer_id, total, status), and how primary keys work. The examples use standard SQL and run on PostgreSQL, MySQL, SQL Server, or SQLite with minor syntax changes.1 min read
03Chapter 3: Wrapping changes in a transactionThis chapter assumes you can write SELECT with WHERE, know primary and foreign keys, and have run INSERT, UPDATE, and DELETE. Examples use the customers and orders tables from earlier in the tutorial. They are written for PostgreSQL and SQLite, and the differences are noted.2 min read