Adding a new column is simple in theory. One ALTER TABLE statement and you are done. In practice, it can lock rows, block queries, and drag performance through the mud. Production workloads choke when schema changes rewrite massive data files or rebuild indexes. The wrong approach can bring your service down for hours.
Choosing the right method matters. On smaller datasets, a direct ALTER TABLE ADD COLUMN works. For large, critical tables, use online schema changes or background migrations. Tools like pt-online-schema-change or native database features can add a column while keeping traffic flowing. Avoid default values that force a full table rewrite. Instead, add the column as NULL and backfill in controlled batches.
Think about the type and storage before you add the column. A TEXT column behaves differently than INT or JSONB in indexes, compression, and query planning. For distributed systems, adding a column in schema registries, ORMs, and service contracts must be coordinated to prevent production errors. Keep migrations idempotent. Run them in staging with production-like data. Measure query plans before and after.