The schema is tight. The migration runs. But the product needs more data, and the answer is simple: add a new column.
Adding a new column to a database table sounds routine. It is routine—until it isn’t. Done wrong, it can lock tables, block requests, and drag down performance. Done right, it’s invisible to the end user. The key is understanding the tools your database provides and the operational impact of each decision.
In PostgreSQL, ALTER TABLE ADD COLUMN is the workhorse. By default, adding a nullable column without a default is instant for most workloads. But the moment you add a default value, older versions rewrite the entire table. On large tables, that rewrite can take minutes or hours, depending on I/O and indexes. In newer releases, adding a column with a constant default skips the rewrite, storing metadata only, which is far faster.
In MySQL, ALTER TABLE can lock the table, depending on the storage engine and column definition. With InnoDB and the right flags, ALGORITHM=INPLACE allows adding a column without rebuilding the entire table. Still, even “in place” operations can be blocking in subtle ways, especially with concurrent DML.