// COMING SOON

What the SQL!

A book for developers who know SELECT * but break into a cold sweat when someone mentions window functions.

-- What most developers write
SELECT * FROM tutorials
WHERE depth = 'parking lot'
AND prepares_you_for = 'rush hour in Manhattan';
-- Returns: 0 rows. You're on your own.
scroll

Sound familiar?

I've had these conversations with clients at least once a month for 20 years.

"We need to migrate to MongoDB."

Translation: Your queries are doing full table scans. You don't need a new database; you need to understand EXPLAIN.

"We should add a caching layer."

Translation: You're calculating aggregations on every request. You don't need Redis; you need materialized views.

"The ORM handles all of that."

Translation: The ORM generated 47 LEFT JOINs to fetch a user profile. It's Tuesday. Your DBA is crying.

20 years of scars, shared freely.

My name is Scott, and I write love poems about SQL. Yes, really.

After two decades of queries that have saved companies millions (and cost them... well, let's not talk about that one DELETE without a WHERE clause), I've learned something important:

SQL isn't just a query language. It's a superpower hiding in plain sight.

"Most SQL tutorials teach you syntax the way a phrasebook teaches you French: enough to order coffee, not enough to have a conversation about philosophy." -- Chapter 1, probably

What's Inside

01

SQL is a State of Mind

Rewire your brain. Think in sets, not loops. Describe what you want, not how to get it.

02

CTEs - Your New Best Friend

Turn spaghetti queries into readable, maintainable code. Named steps. Clear flow. Debugging made possible.

03

Aggregation Superpowers

Window functions, ROLLUP, CUBE, GROUPING SETS. The features that make queries powerful.

04

EXPLAIN Like I'm Five

X-ray vision into query execution. See what the database is actually doing and fix the slow parts.

05

Business Logic Belongs in the Database

Constraints, triggers, functions. Make invalid states impossible. The database as fortress.

06

SQL vs. ORMs - A Peace Treaty

Find the middle ground. ORM where it helps, raw SQL where it's needed. No holy wars.

07

The Value-Driven Query

Ship "good enough" instead of chasing perfect. Focus on impact, not cleverness.

08

SQL is My Love Language

Appreciate the elegant design. 50 years and still going strong. Find the beauty in the syntax.

Get notified when it ships.

No spam. Just one email when the book is ready. I'll even throw in a chapter preview.

waiting_list.sql
INSERT INTO waiting_list
');

-- 1 row inserted. No spam. Ever.