Incorrect dryRunOutput file
Sasha
Posts: 1 New member
Hello,
I use Trial version of Flyway Enterprise edition for testing and possible using in projects. I found strange behavior with -dryRunOutput parameter if is run from Flyway desktop and you have more then one migration script.
If you click on "View Dry Run script", the output is correct with all Callback and migration scripts included. If you click on Run Migrate, with dryRunOutput set to some filename you get file with few same lines - something like
ALTER SESSION SET CURRENT_SCHEMA="Name_of_the_target_schema";
The funny thing is that this is the case only if you have more than one migration scripts (it working correctly if you have just on migration scripts) and even more funny is that if you copy command line from Flyway desktop and run it from command line - you will get the correct file!
Is this some kind of bug or I miss something?
Regards,
I use Trial version of Flyway Enterprise edition for testing and possible using in projects. I found strange behavior with -dryRunOutput parameter if is run from Flyway desktop and you have more then one migration script.
If you click on "View Dry Run script", the output is correct with all Callback and migration scripts included. If you click on Run Migrate, with dryRunOutput set to some filename you get file with few same lines - something like
ALTER SESSION SET CURRENT_SCHEMA="Name_of_the_target_schema";
The funny thing is that this is the case only if you have more than one migration scripts (it working correctly if you have just on migration scripts) and even more funny is that if you copy command line from Flyway desktop and run it from command line - you will get the correct file!
Is this some kind of bug or I miss something?
Regards,
Tagged:
Answers
Thanks for the question!
The function of the dryrun switch is to display the exact commands that are being run and that's what's occurring, flyway is re-establishing target context between migrations to ensure session consistency.