You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The only problem is that when you stick null in the list of allowed values, it seems to accept any other values ... which kind of defeats the entire purpose of setting the constraint in the first place.
Note that this is only a problem if you bypass the ORM to set invalid data in your enum column.
SilverStripe 4 DBEnum are created as table constraint. Those constraints are created using the following SQL statement.
The only problem is that when you stick
null
in the list of allowed values, it seems to accept any other values ... which kind of defeats the entire purpose of setting the constraint in the first place.Note that this is only a problem if you bypass the ORM to set invalid data in your enum column.
There's some related RFC about dropping ENUM support altogether silverstripe/silverstripe-framework#8401 so this might not be worth fixing.
The text was updated successfully, but these errors were encountered: