I have a main table called M1, which consists of the identifiers of three separate tables T1, T2 and T3.
I need to join 3 tables on M1 using my identifiers and display their names. For this, I use the following query:
var query= (from i in dbContext.M1 join j in dbContext.T1 on i.Mt1_id equals j.Mt1_id join l in dbContext.T2 on i.Mt2_id equals l.Mt2_id join s in dbContext.T3 on i.Mt3_id equals s.Mt3_id where i.Mid >= 1 select new { a=j.name, b=l.name, c=s.name }).ToArray();
I used this method, but I get the error " Type inference failed in call to Join "
Can someone tell me where I was wrong?
source share