嗨,我在 SQL 中有这个查询,我想将其转换为 Linq(实体),我是这方面的初学者,我想知道如何:
select k.ID from dbo.Cases k
left join
(
select c.ID, r.RelatedCaseID from dbo.Cases c
inner join
(
select r.RelatedCaseID, r.CaseID from dbo.RelatedCases r where r.CaseID = 368
) r
on c.ID = r.RelatedCaseID
) c
on k.ID = c.ID
where k.ID <> 368 and c.RelatedCaseID is null
我想返回一个返回类型为:IEnumerable 对象的函数。
谢谢你。