EF中的Select * From T Where id In(xxx,xxx)子查询
摘要:
//使用子查询//SQL: Select * From KB_BOMTable Where PartNo in (Select PartNO From KB_MPS Where MPSId='00001')var q1=DBCtx.KB_BOMTable.Where(ent => DBCtx.KB_MPS.Where(t => t.MPSId == MPSId).Select(t => t.PartNo).Contains(ent.PartNo) ); var list= q1.ToList();//使用数组/... 阅读全文
posted @ 2012-07-05 15:08 遗忘海岸 阅读(10458) 评论(0) 推荐(3)
浙公网安备 33010602011771号