Primitive Collections in EF Core 8.0: Simplifying Data Storage with JSON
summary
EF Core 8.0 maps any public IEnumerable<T> of a primitive T to a JSON column so lists of strings or enums serialize as JSON arrays, queries compile to SQL Server using OPENJSON usage with the filter value passed as a parameter for plan reuse, and migrations add only JSON or prefixed columns. A case handling system uses an enum primitive collections for completed steps and a small record as a complex types column mapped to two separate columns, reducing joins and working well for aggregate reads.
AI-written summary · about
chapters (11)
- 0:00EF Core 8 introduction
- 0:51Traditional vs JSON modeling
- 1:57Primitive collections in EF Core
- 3:02Querying with LINQ
- 4:05Banking system use case
- 5:09Complex types explained
- 6:11Configuring complex types
- 7:35Future of JSON mapping
- 8:19JSON storage benefits
- 9:23Hybrid data storage shift
- 10:03Conclusion
related talks
59mBeyond Relational With Entity Framework
37mBeyond Relational with Entity Framework
43mEF Core 8 overview and demo
43mEF Core 9: Evolving Data Access in .NET
01h 01m10 things you didn't know EF Core can do
44m10 things you didn't know EF Core can do
50mEntity Framework Core 2.2 and beyond: what's cooking?
01h 06mSQL ❤️ JSON: The Best of Both Worlds
