The new column appears in the schema like a fresh edge in steel. The migration runs. The data waits for its new home.
Adding a new column is simple to describe and easy to get wrong. The decision is never just “add it.” You choose the name. You choose the type. You define default values and constraints. You plan the impact on reads, writes, and indexes.
In SQL, a new column means updating the table definition. In Postgres:
ALTER TABLE users ADD COLUMN last_login TIMESTAMP DEFAULT NOW();
This changes the structure but not the data already stored. Null values fill the gap unless you define a default. Defaults can bloat migrations if applied to large datasets. Consider adding the column without defaults, then backfilling in batches.
On high-traffic systems, a blocking ALTER TABLE can stall queries. Use migrations in off-peak hours or leverage features like Postgres’s ADD COLUMN with no default for instant operations. If you need the value immediately populated, write a backfill job and deploy in stages.