Removing element from enum not working #8137
Labels
bug/2-confirmed
Bug has been reproduced and confirmed.
kind/bug
A reported bug.
team/schema
Issue for team Schema.
topic: enum
"type"/block `enum`
topic: migrate
Milestone
Bug description
So in a schema if you have any field with an array of enum as type and if you remove the value from that enum, then it should only create one migration file with all changes.
But after the generation of the migration file, if you re-run the migrate command, it will ask for a new migration name and when you entered some name for migration it errors by this. And also it will create a new migration file, like this
How to reproduce
Last
) from enumPosition
.prisma generate --schema=./schema.prisma && prisma migrate dev --schema=./schema.prisma
This will create a new migration file like this
prisma migrate dev --schema=./schema.prisma
Expected behavior
After running the third step it should prompt for anything because the schema isn't changed. And appropriate migration should be done in DB.
Prisma information
Environment & setup
Prisma Version
The text was updated successfully, but these errors were encountered: