You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.
Which client are you using? (Command-line, Java API, Maven plugin, Gradle plugin, SBT plugin, ANT tasks)
Commandline
What database are you using (type & version)?
MySQL 5.7
What operating system are you using?
Linux
What did you do?
I have sql migration files. Inside one of them I wrote USE db. I then ran flyway migrate.
What did you expect to see?
I expected that each migration would be it's own independent transactional session. I did not expect that USE db in one SQL file would leak to affect other SQL files. This would mean possibly things like SET commands would also leak.
What did you see instead?
The USE db caused all subsequent SQL files to fail due to running on the wrong database.
The isolation of each sql file migration makes it easier to integrate generated sql files like from mysql_tzinfo_to_sql, which generates a sql file that needs to run against the mysql database. I had hoped that prepending USE mysql; would be good enough.
The text was updated successfully, but these errors were encountered:
What version of Flyway are you using?
Flyway 4.2.0
Which client are you using? (Command-line, Java API, Maven plugin, Gradle plugin, SBT plugin, ANT tasks)
Commandline
What database are you using (type & version)?
MySQL 5.7
What operating system are you using?
Linux
What did you do?
I have sql migration files. Inside one of them I wrote
USE db
. I then ranflyway migrate
.What did you expect to see?
I expected that each migration would be it's own independent transactional session. I did not expect that
USE db
in one SQL file would leak to affect other SQL files. This would mean possibly things likeSET
commands would also leak.What did you see instead?
The
USE db
caused all subsequent SQL files to fail due to running on the wrong database.The isolation of each sql file migration makes it easier to integrate generated sql files like from
mysql_tzinfo_to_sql
, which generates a sql file that needs to run against themysql
database. I had hoped that prependingUSE mysql;
would be good enough.The text was updated successfully, but these errors were encountered: