Open kamal-github opened 5 years ago
I have my own schema migration utility and I too noticed that Postgres wouldn't allow me to Exec multiple CREATE INDEX CONCURRENTLY. I'm hesitant to suggest that Exec support multiple transactions in a single call, unless there's a clear standard and precedence, less the law of unintended consequences strike. Probably best to split the logic into multiple transactions at the application level.
Is there any solution for that?
Any updates?
I am trying to run the migration, which has tables and indexes(also some are unique and concurrent) creation SQL statement in a single SQL file, but getting the below error.
(details: pq: CREATE INDEX CONCURRENTLY cannot be executed from a function or multi-command string)