- Published on
- Authors
- koskila
How to fix "System.InvalidOperationException: The property 'ItemBody.AdditionalData' could not be mapped because it is of type 'IDictionary', which is not a supported primitive type or a valid entity type. Either explicitly map this property, or ignore it using the '[NotMapped]' attribute or by using 'EntityTypeBuilder.Ignore' in 'OnModelCreating'." in .NET 7 and Entity Framework?
Oof. What even is this title? Descriptive - sure, maybe - but also kinda long. Ah, okay. This article explains how to map complex data types to a SQL database when using Entity Framework. This time, I'm using Fluent API to do this.
![Cover image for How to fix "System.InvalidOperationException: The property 'ItemBody.AdditionalData' could not be mapped because it is of type 'IDictionary', which is not a supported primitive type or a valid entity type. Either explicitly map this property, or ignore it using the '[NotMapped]' attribute or by using 'EntityTypeBuilder.Ignore' in 'OnModelCreating'." in .NET 7 and Entity Framework?](/cdn-cgi/image/sharpen=1,format=auto,quality=90,slow-connection-quality=50,onerror=redirect,fit=scale-down,width=1920/images/13525-2019-11-11_12-01-271.jpg)

















![Cover image for Fixing "An assembly specified in the application dependencies manifest [projectname].deps.json was not found"](/cdn-cgi/image/sharpen=1,format=auto,quality=90,slow-connection-quality=50,onerror=redirect,fit=scale-down,width=1920/images/2577-image-2.gif)