-
Notifications
You must be signed in to change notification settings - Fork 65
Open
Description
When updating an enum multiple values can't be added at the same time so it requires one update statement per value. Altering types in postgres can't be done a mutli-command string which is how the migrations are executed. This requires one migration file per alter statement which can inflate the number of migration files by quite a lot. We've already run into this issue with two different enum causing us to create 9 different migration files. Is it possible to add a feature to allow multiple single queries with a comment between each to break up the multi-command strings?
Example:
-- postgres-migrations disable-transaction
ALTER TYPE test_type ADD VALUE 'Manual';
ALTER TYPE test_type ADD VALUE 'Automatic';
Error:
ALTER TYPE ... ADD cannot be executed from a function or multi-command string
Metadata
Metadata
Assignees
Labels
No labels