Adding a new column is one of the most common schema changes in any database. It can be harmless, or it can bring down production if done without care. Databases store new columns differently depending on engine, storage format, and default values. Some systems rewrite the entire table when you add a column with a default. Others can add it instantly by updating metadata. Knowing which case you’re in determines whether the change takes milliseconds or hours.
For relational databases like PostgreSQL and MySQL, adding a nullable column without a default is usually instant. Adding a column with a non-null default can lock the table and rewrite data. In PostgreSQL, using ADD COLUMN ... DEFAULT ... with a constant in newer versions avoids the rewrite by storing the default in metadata—if you know the syntax. In MySQL, ALTER TABLE with DEFAULT often triggers a full table copy unless you’re on an engine that supports instant DDL. Always check the engine support before attempting it in production.
In columnar databases like ClickHouse, adding a new column is almost always metadata-only. In big data warehouses, schema is often flexible, but the cost comes later, during query execution, when missing column data fills from defaults on read.