String size constraint in array triggers new migration with every migrate #21215
Labels
bug/1-unconfirmed
Bug should have enough information for reproduction, but confirmation has not happened yet.
domain/schema
Issue in the "Schema" domain: Prisma Schema, Introspection, Migrations etc.
kind/bug
A reported bug.
topic: broken migrations
topic: cockroachdb
topic: migrate
topic: native database types
topic: scalar list
[]
Bug description
I have a Prisma schema where I create a table with a column set to be an array of strings with a max size constraint. The first time I run
prisma migrate dev
to sync the DB schema with my Prisma schema, the operation is successful. If I runprisma migrate dev
another time, however, Prisma mistakenly detects that the DB schema is out of sync and prompts to create a new migration. All the migration does it dropping the column and re-adding it again with the same constraint.How to reproduce
prisma migrate dev
onceExpected behavior
Running
prisma migrate dev
a second time does not prompt to create a new migrationPrisma information
Environment & setup
Prisma Version
The text was updated successfully, but these errors were encountered: