我正在使用 MVC3、EF4.1、C#。
我有这个 SQL 代码,我想将其转换为 LINQ,但我正在努力掌握正确的 LINQ,因此我正在向您的专家 LINQ 专家寻求帮助。
从触发器中获取的删除 SQL 是:
DELETE FROM Feature
WHERE NOT EXISTS
(
SELECT
LU1 AS LUID
FROM dbo.CLASS WHERE SectionId = Feature.SectionId AND LU1 = Feature.StdLibraryItemId
UNION
SELECT
LU2 AS LUID
FROM dbo.CLASS WHERE SectionId = Feature.SectionId AND LU2 = Feature.StdLibraryItemId
)
非常感谢提前。