Adding a new column to a database is simple on paper, dangerous in production. Schema changes touch every query, every index, every cache. If handled without care, they cause downtime. If done right, they slip in clean, with zero disruption.
The first step: define the column. Use ALTER TABLE for most relational databases. State the column name, data type, default value, and nullability. Keep it atomic. Complex migrations with multiple changes increase risk.
The second step: consider indexes. If the new column will be part of frequent lookups or joins, add an index after testing. Never add an index blindly—check query plans, run benchmarks, measure write overhead.
The third step: handle data backfill. For nullable columns, backfill can be deferred. For non-null columns with a default, the engine will fill existing rows. If you need computed data, batch updates to prevent lock contention.