Vì một số lý do tại sao nó nói rằng "firstname" không tồn tại trong Entity Entity. Nhưng nó được thiết lập cho thực thể SystemUser. Bất kỳ ý tưởng tại sao nó bị nhầm lẫn? Cảm ơn!Lỗi trong câu lệnh Where in LINQ
var linqQuery = (from r in gServiceContext.CreateQuery("opportunity")
join c in gServiceContext.CreateQuery("account") on ((EntityReference)r["accountid"]).Id equals c["accountid"]
join u in gServiceContext.CreateQuery("systemuser") on ((EntityReference)r["ownerid"]).Id equals u["systemuserid"]
where r["new_leadstatus"].Equals("100000004") && u["lastname"].Equals(rsmLastName) && u["firstname"].Equals(rsmFirstName)
select new
{
AccountId = !r.Contains("accountid") ? string.Empty : r["accountid"],
Account = !r.Contains("name") ? string.Empty : r["name"]
});
Không biết bạn có thể có hai câu lệnh. làm việc như say mê, cảm ơn! –
Tìm hiểu điều gì đó mới mỗi ngày. Cảm ơn @Peter –
Chỉ cần dành một vài giờ đập đầu của tôi chống lại bức tường trên này. Cảm ơn bạn. –