1
Answer

C# linq use 3 tables

Ask a question
dc

dc

12y
897
1
In a C# 2008 application, I have the following linq to sql statement setup so far. 

eDataContext eData = new eDataContext();
  var eSelect = (from iw in eData.Ibooks
  join ip in etData.IPack on iw.P_ID equals ip.P_ID
  join eTrack in eData.eRPT_Trans
  on ip.TNum equals eTrack.P_ID
  where ip.TNum == packageId 
  select iw).FirstOrDefault();

I want to obtain values from the 3 different tables listed in the statement aove.
How do I change the linq statement above so that I can obtain data from all three tables?

Thus can you show me how to obtain data from all 3 tables?

Answers (1)