I'm writing a LINQ to SQL statement, and I'm after the standard syntax for a normal inner join with an ON
clause in C#.
How do you represent the following in LINQ to SQL:
select DealerContact.*
from Dealer
inner join DealerContact on Dealer.DealerID = DealerContact.DealerID
Where student and course tables have primary key and foreign key relationship
Actually, often it is better not to join, in linq that is. When there are navigation properties a very succinct way to write your linq statement is:
It translates to a where clause: