The fix needed a new column. Not someday. Now.
Adding a new column to a production database is never just one step. You have to define the schema change, migrate data without blocking critical writes, and guard against hidden downstream failures. Whether you’re using PostgreSQL, MySQL, or a columnar store, the pattern is the same: plan, change, verify.
Start with schema definition. In SQL databases, ALTER TABLE is the common entry point. Adding a new column with a default value can lock the table if you’re not careful. In MySQL pre-8.0, this can be a blocking operation. PostgreSQL is better for certain cases, adding new nullable columns or constants instantly. But when you need computed or indexed data, migrations get heavier.
In distributed systems, a new column is also a contract change. Schema changes must be backward-compatible with old application code. Deploy the change in phases. First add the column as nullable or with a safe default. Then roll out application code that starts writing to it. Only after reads are proven safe should you add constraints or remove legacy columns.