The table waits. Its schema is fixed, its rows locked in place. Then the requirement hits: you need a new column.
Adding a new column is not hard. Doing it right is hard. Poor planning can slow queries, break APIs, or corrupt data expectations. The key is to balance speed and safety.
First, identify the purpose of the new column. Decide the data type. Use the smallest type that still meets the need—reduce storage and speed up scans. Avoid nullable columns unless the nulls are meaningful, because they add complexity in indexing and analytics.
Next, check constraints. Will the new column require a default value? For large tables, setting defaults during creation is faster than updating millions of rows later.
Plan for indexes. Don’t add them automatically. Extra indexes can crush insert performance. Benchmark with and without them before committing.