SQLAlchemy and Alembic 2 · Alembic migrations
Apply migrations
Upgrade the database to the latest revision.
alembic upgrade head
Caution: Back up production data and review the migration before running it.
Official SQLAlchemy and Alembic 2 documentation
More alembic migrations commands
- Install Alembic
- Create a migration environment
- Generate a migration
- Undo the last migration
- Check the current revision
- List migrations
All alembic migrations commands · SQLAlchemy and Alembic 2 cheatsheet