Adding a new column should be simple, but schema changes in production often aren’t. The risk of downtime, locks, and broken apps turns a basic alteration into a planning exercise. You want zero-impact migrations, instant visibility, and a rollback that works.
In relational databases like PostgreSQL, MySQL, and SQL Server, adding a new column changes the table definition. Depending on defaults and constraints, this can trigger a full table rewrite. Large tables suffer from locking that blocks reads and writes. For high-traffic apps, even milliseconds of blocking can cascade into failures.
Best practice is to run the new column migration in phases. First, add the column as nullable with no default. This avoids heavy rewrites. Then, backfill the values in small batches to keep load steady. After the backfill, set sensible defaults and constraints. In distributed systems, deploy code that can handle both old and new schemas before finalizing constraints.