错误:v6.1.3(& v6.1.2):延迟LINQ执行(/多语句)错误 [英] Bug: v6.1.3 (& v6.1.2): Deferred LINQ execution (/multi-statement) bug
问题描述
Guys& Gals,除非我不理解EF工作/应该如何工作的微妙之处,当你在单独的C#-statements中分解LINQ查询时,你似乎有v6.1.3的错误;例如这是有效的:
$
var fullQry =
dbCtx.BldAs.AsNoTracking()。ToList();
Guys & Gals, unless I don't understand a subtlety of how EF works/should work, you seem to have a bug with v6.1.3, when breaking-up LINQ queries across separate C#-statements; e.g. this works:
var fullQry =
dbCtx.BldAs.AsNoTracking().ToList();
但这会引发异常:
But this throws an exception:
(IQueryable< BldA>)dbCtx.BldAs;
(IQueryable<BldA>)dbCtx.BldAs;
推荐答案
您好Deanus1,
Hi Deanus1,
根据您的描述,我遇到类似问题,似乎是一个实体框架6.1.3问题,我可以建议你可以将你的实体框架版本升级到6.2.0。这是实体框架中最重要的变化
6.2.0。
According to your description, I have encounter the similar issue, it seems that is a entity framework 6.1.3 issue, I could suggest that you could upgrade your entity framework version to 6.2.0. Here is the most important changes in entity framework 6.2.0.
https://blogs.msdn.microsoft.com/dotnet/2017/10/26/entity-framework-6-2-runtime-released/
此外,实体框架一直是开源的。您可以从以下链接查看相关的源代码。
In addition, entity framework have been open source. you could check related source code from the following link.
https://github.com/aspnet / entityframework6 /
祝你好运,
张龙
这篇关于错误:v6.1.3(& v6.1.2):延迟LINQ执行(/多语句)错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!