LINQ doesn't define keywords for cross join, left join, or right join.
As part of the LINQ grammar, you get join and group join.
The two common joins are the inner join (or just join in LINQ) and the left join. Suppose you have two collections of data. One you will call the master or left collection, and the other you'll call the detail or right collection. A left join is a join whereby all of the elements from the left collection are returned and only elements from the right collection that have a correlated value in the left sequence. Usually, the correlation is a key or some kind of unique identifier.
Using another analogy, if the left collection is the parent and the right is the child, a left join is all parents but only children with parents.
A right join returns orphans but no childless parents.
developer.com - Implementing a Left Join with LINQ
No comments:
Post a Comment