db-migrate / db-migrate/pg

Not able to add enum value through Migration script

Open
#63 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
68
Forks
50
PR merge metrics
No merged PRs in 30d

Description

As the migration scripts used to run in a single transaction , when trying to run the db-migrate:up for pg, getting the below error.
ALTER TYPE ... ADD cannot run inside a transaction block

Query that i am trying to run in script.

ALTER TYPE document_type ADD VALUE 'new value' AFTER 'existing value';
package version i am using in project .
"pg": "^8.5.1",
"db-migrate": "^0.11.11",
"db-migrate-pg": "^1.2.2",

Is there any workaround to skip the transaction for a particular or any suggestions ? It would be very helpful

---
Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/98010079-not-able-to-add-enum-value-through-migration-script?utm_campaign=plugin&utm_content=tracker%2F14258523&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F14258523&utm_medium=issues&utm_source=github).

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.