Flyway Desktop can automatically generate Undo scripts to help with rollbacks
StephanieHerr
Redgate › Posts: 174 Gold 1
Flyway Desktop tracks changes to a development database in a schema model on disk so it can be versioned controlled to understand how each object changes over time and provides better team collaboration. When ready to deploy these changes, you can generate a Versioned migration script (a V script), which can be customized so you have full control over the deployment. These V scripts can be manually deployed to other environments using the Migrations tab in Flyway Desktop or used as part of an automated CI/CD pipeline.
As of Flyway Desktop v5.13.4, you can decide if you want to generate a corresponding Undo migration script (a U script) every time you generate a V script. The U script is responsible for undoing the effects of the versioned migration with the same number. For example, V003.001__AddEmployeeAddress.sql would have a corresponding U003.001__RemoveEmployeeAddress.sql. These U Scripts can be versioned controlled alongside the schema model and V scripts and can be tested manually or as part of an automated process.
This is an option because some teams prefer to roll forward fixes instead of rolling back. It's very important to have a plan in place if something goes wrong. Be extra careful if the scripts involve data changes.
Learn more about generating undo migration scripts.
Flyway Desktop fully supports Oracle, SQL Server, PostgreSQL and MySQL. Please let us know what databases you are work with.
As of Flyway Desktop v5.13.4, you can decide if you want to generate a corresponding Undo migration script (a U script) every time you generate a V script. The U script is responsible for undoing the effects of the versioned migration with the same number. For example, V003.001__AddEmployeeAddress.sql would have a corresponding U003.001__RemoveEmployeeAddress.sql. These U Scripts can be versioned controlled alongside the schema model and V scripts and can be tested manually or as part of an automated process.
This is an option because some teams prefer to roll forward fixes instead of rolling back. It's very important to have a plan in place if something goes wrong. Be extra careful if the scripts involve data changes.
Learn more about generating undo migration scripts.
Flyway Desktop fully supports Oracle, SQL Server, PostgreSQL and MySQL. Please let us know what databases you are work with.
Thank you!
Stephanie M. Herr :-)
Product Manager Database DevOps
Stephanie M. Herr :-)
Product Manager Database DevOps
Tagged:
Comments
Within each project there is now a cog icon for configuration that will present this option.
The former config file setup remains viable also.