Hey guys, does prisma support CHECK constraint out...
# orm-help
b
Hey guys, does prisma support CHECK constraint out of the box? Like defining it in the schema.
1
n
Hey Brook 👋 Not possible in the schema directly, but you can use Migrate to achieve this: 1. Create the migration using
prisma migrate dev --create-only
2. Edit the generated
.sql
file and add the check constraint 3. Run
prisma migrate dev
to apply the migration.
🙌 1