Migration Patterns
Most operators only need a handful of migration patterns. Choose one first, then refine it for your schema.
Patterns
Section titled “Patterns”- Minimal-safe for first production rehearsals and cautious cutovers
- Recreate-fast for disposable environments and quick repeat runs
- Chunked-resume for large tables and interruption-prone jobs
- Schema-only and data-only for split-phase execution
- Hooks-driven migrations when you need follow-up SQL around the built-in pipeline
How to decide quickly
Section titled “How to decide quickly”| Situation | Start with |
|---|---|
| First real migration, production data matters | Minimal-safe |
| Dev or staging database can be dropped and rebuilt | Recreate-fast |
| Load is long enough that restart cost matters | Chunked-resume |
| You need to inspect DDL before loading data | Schema-only and data-only |
| You must recreate views, routines, or cleanup SQL | Hooks-driven migrations |