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
publicclassJobDefinition{[Required]publicGuidJobDefinitionId{get;set;}[Required]publicintVersion{get;set;}[Required]publicGuidTenantId{get;set;}[Required]publicJobTypeJobType{get;set;}[Required]publicstringActionType{get;set;}[Required][Column(TypeName="jsob")]publicDictionary<string,string> Properties {get;set;}// Refers to another entitypublicList<ScheduleJobDefinitions> ScheduleJobDefinitions {get;set;}}
If I understand correctly, this should work and convert the dictionary to a json object.
When generating the migration using dotnet ef migrations add DbInitial -o Database/Migrations, the program builds but then gives the following error: The type mapping for 'Dictionary<string, string>' has not implemented code literal generation.
What could be going on? I have also tried [Column(TypeName="hstore")], but that didn't make a difference unfortunately.
I use .NET Core 3.1.2 with Entity Framework Core.
Thanks in advance.
The text was updated successfully, but these errors were encountered:
You're probably trying to seed hstore data (with the HasData API). Unfortunately that's not possible currently - I'll keep this open and will try to look into it at some point.
Hi,
I have a model as follows:
If I understand correctly, this should work and convert the dictionary to a json object.
When generating the migration using
dotnet ef migrations add DbInitial -o Database/Migrations
, the program builds but then gives the following error:The type mapping for 'Dictionary<string, string>' has not implemented code literal generation.
What could be going on? I have also tried
[Column(TypeName="hstore")]
, but that didn't make a difference unfortunately.I use .NET Core 3.1.2 with Entity Framework Core.
Thanks in advance.
The text was updated successfully, but these errors were encountered: