Introspection removes enums and replaces with DB column type #4770
Labels
kind/feature
A request for a new feature.
team/client
Issue for team Client.
tech/engines/introspection engine
Issue in the Introspection Engine
Bug description
When specifying enums as the values on a prisma model, those enums get replaced with a
String
type after running introspection.Before introspection:
After introspection:
Here is the
CREATE TABLE
expression for thegoals
table. Take special note that thetype
column is not a PostgreSQL enum, but rather atext
column with aCHECK
constraint.Expected behavior
I would expect that if running introspection on a column that is already defined by the prisma schema and the column type is defined by a custom enum (the enum being specified in the prisma schema), that the introspection would not replace the enum type to a
String
type.Environment & setup
The text was updated successfully, but these errors were encountered: