Adding a new column sounds simple. In practice, it can break production if you get it wrong. Schema changes touch live data, and every bad decision compounds over time. Choosing the wrong column type, forgetting null constraints, or missing an index can turn a one-minute deploy into an hour of downtime.
When adding a new column in SQL, define the exact type first. Never leave it at a default you didn’t choose. Decide on NULL versus NOT NULL before adding it; changing later locks the table for longer. If you need a default value, set it in the migration to avoid slow updates.
For large datasets, add the column without heavy operations in the same transaction. Avoid full table rewrites unless absolutely required. If you need to backfill data, do it in batches to prevent table locks. Always test migrations on a realistic copy of production data before pushing live.