// the take
A free, CC-licensed PostgreSQL tutorial written as a sequence of short Markdown lessons, each paired with a runnable .sql file, taking a reader from SELECT basics through joins, CTEs, window functions, triggers, and into operational topics like VACUUM, pg_dump, and roles. It's aimed at developers who want to learn Postgres by running real queries rather than reading a reference manual.
Every lesson ships an executable .sql file you run with psql and compare output against, not just prose and screenshots. Coverage goes well past the usual SELECT/JOIN tutorial stopping point into things most SQL books skip: EXPLAIN and query plans, materialized views, full-text search, savepoints, and basic role/GRANT security. Version requirements are called out per-feature (gen_random_uuid() needs 13+, MERGE needs 15+) instead of silently assuming one Postgres version. It's free and CC BY 4.0, with no signup wall for content that's often sold as a paid course.
Lessons are stateful and order-dependent — many reuse tables created in earlier chapters (fruits, orders_example) against a single shared postgres database, so jumping into the middle of the book means manually hunting down and re-running prior scripts first. There's no CI or test harness verifying the SQL examples actually produce the stated output against current PostgreSQL releases, so examples can silently drift as default behaviors change across versions. The postgis topic tag is misleading — there is no PostGIS or geospatial content anywhere in the table of contents. Nothing on replication, partitioning, or connection pooling, so it stops right where a reader would need guidance to run Postgres beyond a single toy instance.
We read the README, the directory tree and a key source file in October 2026. Nobody pays to be listed. How we judge →