
Adding a column on a small table is instant. Adding one with a default on a large table, changing a column type or creating an index can lock the table for minutes, and every request touching it waits or fails.
| Change | Risk | Safer approach |
|---|---|---|
| Add nullable column | Low | Safe in most databases |
| Add column with default on huge table | Can lock (older versions) | Add nullable, backfill, then set default |
| Create index | Locks writes | Create concurrently |
| Rename column | Breaks running code | Expand-contract over several releases |
| Change column type | Rewrites table | New column, backfill, switch |
| Drop column | Breaks old code | Stop using first, drop later |
Tired of risky deployments and surprise downtime?
We set up CI/CD, monitoring and infrastructure that lets your team ship calmly.
Update large tables in batches of a few thousand rows with short pauses, outside the main deployment. This keeps locks short and load manageable, and lets you stop and resume safely.
Django generates migrations, but you must still review them for locking and plan multi-step changes.
Some can; data-destroying ones cannot. Expand-contract keeps rollback possible.
Yes. We review schema changes and plan safe rollouts.
Tired of risky deployments and surprise downtime?
We set up CI/CD, monitoring and infrastructure that lets your team ship calmly.
Comments (0)
Sign in to comment.