The schema is wrong. The product team knows it. The data team knows it. Yet shipping grinds to a halt because the database needs a new column.
Adding a new column is simple in theory. In practice, it is an operation with ripple effects across storage, APIs, and application logic. Done incorrectly, it can lock tables, break queries, and cause downtime. Modern engineering teams need a process that handles these changes in minutes, not days.
The first step is understanding the constraints. On large tables, altering schema can be expensive. For relational databases like PostgreSQL or MySQL, adding a column without defaults is fast. Adding a column with a default value that forces a table rewrite can be slow and block writes. Engineers should avoid schema changes that rewrite every row unless necessary.
Plan migrations for zero downtime. Use online schema change tools or built-in features like PostgreSQL’s ADD COLUMN without DEFAULT, followed by an UPDATE in small batches. This keeps the application responsive while the new column is backfilled.