Free downloads
Everything you need to follow along with the book — the sample database plus every example query, ready to run. No sign-up required.
Choose your database
Setup builds the practice database (5 tables, ~980 rows) and the Lesson 8 sample function. Queries holds every example from the book, in order, so you can follow along.
Quick start
Prefer a local install? Open the Setup script in SQL Server Management Studio, MySQL Workbench, or pgAdmin and run it there. It builds the tables and loads the data in one step.
What's inside
A deliberately simple world of pet owners and their animals, so you can focus on learning SQL instead of decoding the data.
Get the full walkthrough
Every script here is explained step by step across 20 short lessons in From Zero to SQL in 20 Lessons.