Migrations: Default value not scaffolded for non nullable fields causing error #1275
Labels
closed-fixed
The issue has been fixed and is/will be included in the release indicated by the issue milestone.
type-bug
Milestone
Consider a database with tables and user data. Now if I change my model to add a property, say
DateTime
which is non nullable. Running migrations generates the necessary code but doesn't set a default value for the column. This causes to throw an ugly EF exception when applying the migrations that there is no default value set.This seems to have worked in EF 6.0 where a default value was set for the column
The text was updated successfully, but these errors were encountered: