- 114.3k
- 14
- 149
- 202
var activeDetails1 = await ctx.LogicPointWorkFlowDetails
.Where(x => x.Status == Lms.UnifiedContextDb.Models.Enums.WorkFlowStatus.Active)
.Where(x => x.WorkFlow != null
&& x.WorkFlow.Blocks != null
&& x.WorkFlow.Blocks.Any(g => g.LogicPointWorkFlowBlockId != null
&& blockIds.Contains(g.LogicPointWorkFlowBlockId)))
.Select(x => x.WorkFlow)
.ToListAsync();
var activeDetails1 = await ctx.LogicPointWorkFlowDetails
.Where(x => x.Status == Lms.UnifiedContextDb.Models.Enums.WorkFlowStatus.Active)
.Where(x => x.WorkFlow != null
&& x.WorkFlow.Blocks != null
&& x.WorkFlow.Blocks.Any(g => g.LogicPointWorkFlowBlockId != null
&& blockIds.Contains(g.LogicPointWorkFlowBlockId)))
.Select(x => x.WorkFlow)
.ToListAsync();
var activeDetails1 = await ctx.LogicPointWorkFlowDetails
.Where(x => x.Status == Lms.UnifiedContextDb.Models.Enums.WorkFlowStatus.Active)
.Where(x => x.WorkFlow != null
&& x.WorkFlow.Blocks != null
&& x.WorkFlow.Blocks.Any(g => g.LogicPointWorkFlowBlockId != null
&& blockIds.Contains(g.LogicPointWorkFlowBlockId)))
.Select(x => x.WorkFlow)
.ToListAsync();
EF Core 8 JSON column mapping – navigation property throws NullReferenceException
I'm using C# with .NET 8 and Entity Framework Core 8.0.1 with a SQL Server 2019 database.
I have a model with a WorkFlow column in the database, defined as nvarchar(MAX) and storing JSON data. Previously, we treated it as a plain string in our C# entity, but I'm now trying to take advantage of EF Core 8’s JSON column mapping feature to deserialize it directly into a strongly typed object.
EF Core 8 JSON column mapping – navigation property throws NullReferenceException
I'm using C# with .NET 8 and Entity Framework Core 8.0.1 with a SQL Server 2019 database.
I have a model with a WorkFlow column in the database, defined as nvarchar(MAX) and storing JSON data. Previously, we treated it as a plain string in our C# entity, but I'm now trying to take advantage of EF Core 8’s JSON column mapping feature to deserialize it directly into a strongly typed object.
JSON column mapping – navigation property throws NullReferenceException
I have a model with a WorkFlow column in the database, defined as nvarchar(MAX) and storing JSON data. Previously, we treated it as a plain string in our C# entity, but I'm now trying to take advantage of EF Core 8’s JSON column mapping feature to deserialize it directly into a strongly typed object.