-
-
Notifications
You must be signed in to change notification settings - Fork 321
Closed
Labels
autogenerate for enumsa long term subject, tagging issues related to thisa long term subject, tagging issues related to thismigration environmentop directivespostgresqluse casenot quite a feature and not quite a bug, something we just didn't think ofnot quite a feature and not quite a bug, something we just didn't think of
Description
Migrated issue, originally created by Wichert Akkerman (@wichert)
Unfortunately not all DDL commands for PostgreSQL can be used in a transaction. I ran into this when trying to add a new value to an enum:
db=# BEGIN;
BEGIN
db=# ALTER TYPE article_type ADD VALUE 'unknown';
ERROR: ALTER TYPE ... ADD cannot run inside a transaction block
I'm not sure what the best way to handle this is in alembic currently. Perhaps do op.execute('COMMIT') manually? Perhaps alembic needs an in-between-commit operation for this.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
autogenerate for enumsa long term subject, tagging issues related to thisa long term subject, tagging issues related to thismigration environmentop directivespostgresqluse casenot quite a feature and not quite a bug, something we just didn't think ofnot quite a feature and not quite a bug, something we just didn't think of