The query was slow. The schema was wrong. The fix was simple: add a new column.
A new column in a database changes how data is stored, retrieved, and scaled. Done right, it supports new features without breaking existing ones. Done wrong, it locks you into performance issues and costly migrations. The difference comes down to planning, tooling, and execution.
When adding a new column, start with the data type. Choose types that match the expected size and precision of the data. Avoid defaults that waste space or mismatch future requirements. Set nullability and constraints with intention—never as an afterthought.
In production systems, adding a new column can cause lock contention or replication delays. Reduce impact with non-blocking schema migration strategies. Add the column without a default, backfill in small batches, then apply constraints once the data is complete. This approach keeps services online and queries fast.