The specified type member 'IsLock' is not supported in LINQ to Entities. Only initializers, entity members, and entity navigation properties are supported.
var query = from C in objDb.GetDb<A>()
join a in objDb.GetDb<B>().Where(m => m.ComputerID != null)
on C.Email equals a.Email
select new C
{
};
EF 执行错误:The specified type member 'IsLock' is not supported in LINQ to Entities. Only initializers, entity members, and entity navigation properties are supported.
原因:new 的时候要初始化大括号的属性值
修改后
GridDto<DownRegistrationDto> entityDb = new GridDto<DownRegistrationDto>();
var query = from C in objDb.GetDb<a>()
join a in objDb.GetDb<b>().Where(m => m.ComputerID != null)
on C.Email equals a.Email
select new C
{
DID = C.DID, ProductID =C.ProductID,ProductName =C.ProductName,FepVersion =C.FepVersion
};
The specified type member 'IsLock' is not supported in LINQ to Entities. Only initializers, entity members, and entity navigation properties are supported.的更多相关文章
- The specified type member 'Date' is not supported in LINQ to Entities. Only initializers, entity members, and entity navigation properties
出现这个错误提示可以用 DbFunctions.TruncateTime 将Linq中entity的DateTime转化一下再使用,如下所示: var anyCalls = _db.CallLogs. ...
- The specified type member 'Date' is not supported in LINQ to Entities. Only initializers, entity members, and entity navigation properties are supported.
使用EF时,在Limda表达式中( query.Where(x => x.CheckInDate >= bd.Date);)查询的时候抛出了这个异常,网上查到的发现,并不能解决问题. 后来 ...
- 记录一个EF连接查询的异常:the entity or complex type 'x' cannot be constructed in a linq to entities query
问题解决连接:https://stackoverflow.com/questions/5325797/the-entity-cannot-be-constructed-in-a-linq-to-ent ...
- #define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)宏的运行机理:1. ( (TYPE *)0 ) 将零转型为TY ...
- (转)内核container_of(ptr,type,member) 解析
container_of(ptr,type,member) 用于在已知结构体里面成员member和该成员指针ptr(就是地址)和结构体类型type, 返回该成员所在的结构体的指针(就是地址), 例如 ...
- list_entry(ptr, type, member)——知道结构体内某一成员变量地址,求结构体地址
#define list_entry(ptr, type, member) \ ((type *)(() -> member))) 解释: 1 在0这个地址看做有一个虚拟的type类型的变量,那 ...
- 对list_entry(ptr, type, member)的理解
如何根据一个结构体成员的地址.结构体类型以及该结构体成员名获得该结构体的首地址? #define list_entry(ptr, type, member) \ ((type *)((char *)( ...
- #define IOFFSETOF(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
#include <iostream> #define IOFFSETOF(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER) usi ...
- EF C# ToPagedList方法 The method 'Skip' is only supported for sorted input in LINQ to Entities. The method 'OrderBy' must ……
报错信息:The method 'Skip' is only supported for sorted input in LINQ to Entities. The method 'OrderBy' ...
随机推荐
- log4erl API
https://github.com/ahmednawras/log4erl/blob/master/API.txt NOTE:=====Please be informed that the API ...
- 对raid几个技术的简单理解
磁盘阵列(Redundant Arrays of Independent Disks,RAID),有“独立磁盘构成的具有冗余能力的阵列”之意,主要体现在两方面: 1.HA 高可用性,也就是冗余 2.L ...
- rebar工具使用备忘录
http://cryolite.iteye.com/blog/1159448 rebar是一个开源的erlang应用自动构建工具.basho的tuncer开发.它实际上是一个erlang脚本(escr ...
- 【33.33%】【codeforces 586D】Phillip and Trains
time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard ou ...
- web IDE Eclipse Che安装
安装:使用安装器安装 使用安装器安装Che 环境 依赖 下载地址 通用 任何操作系统,java8,Git,Maven 3.0.5+,Docker 1.7+ 3.12.52 - 117MB window ...
- module.exports输出的属性被ES6如何引用的
阮一峰的ES6教程里有讲: import 命令加载 CommonJS 模块 Node 采用 CommonJS 模块格式,模块的输出都定义在module.exports这个属性上面.在 Node 环境中 ...
- SQL Server 存储过程之嵌套游标
下面是一个订单取消的含2个游标的存储过程 set ANSI_NULLS ON set QUOTED_IDENTIFIER ON go ALTER PROCEDURE [dbo].[CancelOrde ...
- 一个2013届毕业生(踏上IT行业)的迷茫(5)
很快就到了该找工作的时间了,听说这一年是历史上找工作的人对多的一年,我也不知道是怎么统计的,可信不可信.跑了大概快一个月了,终于有offer了,就这样在这里实习了3个月,一直工作到现在. 回忆了整个学 ...
- 获得WIN7管理员权限(可通过修改注册表,或者组策略改变)
在使用WIN7过程中,常常会再出现没有管理员权限而不能正常运行软件(有的软件直接就是打不开,有的软件不能正常运行(比如如果没有管理员权限,keil就不能注册成功))....也许你会说,我的电脑里只有一 ...
- QWidget之Alien与Native小记(果然是DirectUI的方式,QWidget居然提供了nativeParentWidget函数,而且可以动态设置native父窗口)good
在QWidget 之paint部分杂记提到了从Qt4.4开始,Alien Widget被引入.那么...这是什么东西呢,我们在使用中又可能会感受到什么东西? 用例子来说话似乎比用源码来说话来得容易,所 ...