var obj = from r in db.ParentTables
where r.ChildTable.Count > 0 // && How can we get the Child table data by parsing value by query string.? for eg: r.ChildTable.Language= English
select r;
我需要将返回的查询维护为r,即IEnumerable
答案 0 :(得分:1)
如果我理解你的问题,正在寻找类似的东西
var obj = from r in db.ParentTables
where r.ChildTable.Any(c => c.Language = "English")
select r;
答案 1 :(得分:0)
var obj = from r in db.ParentTables
where r.ChildTable.Any(c => c.Count() > 0 && c.Language == "English")
select r;