Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to discard a migration after undoing it #2288

axelfontaine opened this Issue Jan 30, 2019 · 1 comment


None yet
1 participant
Copy link

axelfontaine commented Jan 30, 2019

Customer report

I started with this:

I then rolled back V4, and got this:

At this point you say I can ‘discard it altogether’. So I tried deleting the files, which led to this (note the missing status):

Attempting a migrate at this stage leads to this:

So I’m not clear on how I can discard an undone migration?

At this point I tried the second scenario of amending the V4 file. So I renamed the file from V4__Another_person.sql to V4__Another_person_next_try.sql. If I delete the corresponding U4__Another_person.sql, I get this:

And if I leave the U4__Another_person.sql in place I get this:

But either way, the result of attempting a migrate is this:

So finally I tried leaving the existing versions of V4__Another_person.sql and U4__Another_person.sql in place and adding V4__Another_person_next_try.sql as well. This led to the following:

So I’m not clear on how I can either re-implement a previous version or completely abandon it…

Note that the only thing that did work was to edit the contents of the undone file without altering the name and then running migrate – but this doesn’t help in the case where I want to undo a change and completely discard it, or replace it with something different (so that the description from the file is no longer applicable).

@axelfontaine axelfontaine added this to the Flyway 6.0.0 milestone Jan 30, 2019

axelfontaine pushed a commit to flyway/ that referenced this issue Feb 11, 2019


This comment has been minimized.

Copy link
Contributor Author

axelfontaine commented Feb 11, 2019


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.