The board waited. The query ran. But the result was wrong because the schema was stale.
Adding a new column should be simple. In practice, it’s where production slows, migrations pile up, and downtime risks surface. Whether you work with PostgreSQL, MySQL, or any relational database, the moment you alter a table you expose dependencies. ORM models break. API contracts fail. Batch jobs throw errors. The fix is not just to add a new column—it’s to add it without breaking the system.
A safe new column migration starts with schema versioning. Use explicit ALTER TABLE statements. Apply them in small, reversible steps. Never couple a column addition with data backfills in the same deployment. First, create the column as nullable. Ship the code that writes to it. Only when writes are stable do you enforce NOT NULL or add constraints.