Strapi Enum Proplem

System Information
  • Strapi Version: 4.0.2
  • Operating System: Windows
  • Database: PostgreSQL

Is it me or is strapi accept just six values for enum data type??? when I’m trying to choose the seventh enum value it gives internal server error that says:

insert into "products" ("active", "adschange", "canoffer", "chat", "created_at", "created_by_id", 
"enddate", "language", "name", "productmessage", "published_at", "rate", "startdate", "status", "unit", "updated_at", "updated_by_id") values ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17) returning "id" - new row for relation "products" violates check constraint "products_unit_check"

And when I choose the sixth or less enum value it work like charm

I tried to change values and create even new enum type but still the same behavior

@Louai_Kelani did you end up solving this, running into a similar issue :thinking:

Looks like once the table is created and data is populated, the constrains can’t be modified.

This is dumb which means we can’t add new enum items.

1 Like