Adding a new column sounds simple. It is not. A single schema change can disrupt production, slow queries, or cause silent data loss. The key is to plan, execute, and monitor with zero downtime.
First, define the purpose of the new column. Decide on data type, default values, nullability, and indexing before touching the database. Locking the wrong table in production can stall an entire service.
Second, choose a safe migration strategy. For large tables, avoid direct ALTER TABLE operations that block for minutes or hours. Use online schema change tools, background jobs, or phased rollouts to backfill data. Test the change in staging with production-like load before deploying.