Support for Redshift statements which cannot be run inside a transaction #1879
I found that flyway cannot create an external table because it does not recognise it must be run in a transaction. I have forked flyway and believe I have made the necessary addition here gareth625@f6b404d. My Java isn't good enough to find and add a unit tests but I have built the JAR and tested against a Redshift cluster.
Unfortunately I haven't tested the migrations I have included as I'm having trouble accessing my company's AWS resources externally. I wanted to get the ball rolling though and the changes into a commitable state.
What version of Flyway are you using?
Which client are you using? (Command-line, Java API, Maven plugin, Gradle plugin, SBT plugin, ANT tasks)
What database are you using (type & version)?
What operating system are you using?
What did you do?
(Please include the content causing the issue, any relevant configuration settings, and the command you ran)
Ran a migration to create an external schema on a Redshift cluster using Athena catalogue which succeeds:
then tried to create an external table in the schema, for example:
which fails as you cannot create an external table in a transaction.
This I did using two migrations with the flyway command line tool.
What did you expect to see?
Creation of the external schema and table.
What did you see instead?
The creation of the external schema but not the table.
The text was updated successfully, but these errors were encountered:
The current implementation (derived from the PostgreSQL one) also incorrectly looks for
These checks should be removed.
This has now been fixed. For