I would need some guidance to convert this query in LINQ (method-based or expression syntax):
SELECT * from table1 t1
JOIN table2 t2 ON t1.fieldA = t2.fieldA and t1.fieldB = t2.fieldB
JOIN table3 t3 ON t2.fieldC = t3.fieldA
WHERE
t3.Enabled=1 and
t2.Active = 1 and
t1.Linked=1;
Using expression syntax it seems logical operators are not supported in the join clause.
My failed attempt:
var query = from t1 in context.table1
join t2 in context.table2 on t1.fieldA equals t2.fieldB && t1.fieldB equals t2.fieldB
join t3 in context.table3 on t3.fieldA equals t3.fieldC
where
t1.Enabled == 1 && t2.Active == 1 && t3.Linked == 1;