The query ran. The table was ready. But the schema needed a new column.
Adding a new column can be trivial or it can cripple production. It depends on your approach. Schema changes demand precision. A careless ALTER TABLE can lock rows, block writes, or spike CPU under load.
First, check size. On large datasets, adding a new column without defaults or constraints is faster. Avoid backfilling during peak traffic. If defaults are required, consider creating the column as NULL and updating in controlled batches.
Use transactional DDL when supported. This ensures your new column is created atomically. In systems without transactional DDL, plan for rollback. Keep migrations in version control, and run them through staging with realistic data.