Seed entity with owned property
问题 I am trying to seed an user entity in my database. The User entity has an owend property EmailPermissions . When I run the command dotnet ef migrations add Initial; I get the error The seed entity for entity type 'User' cannot be added because it has the navigation 'EmailPermissions' set. To seed relationships you need to add the related entity seed to 'EmailPermissions' and specify the foreign key values {'UserId'}. but since EmailPermissions is an owned entity I didn't give it an explicit