title: LINQ Group by performing join across multiple tables/classes
body: <p>I have a table structure in my DB like this:</p>
  
  <pre><code>Items &lt;=  User  =&gt; Transactions
  </code></pre>
  
  <p>So in C# mapped classes User contains a collection of Items and Transactions... (1 to many relationship)..</p>
  
  <p>So now what I've done is following:</p>
  
  <pre><code>   var filteredProducts = ctx.Transactions.Where(x =&gt; x.SearchedUserID == 
      firstRequest.SearchedUserID)
      .OrderByDescending(x =&gt; x.TransactionDate)
      .GroupBy(x =&gt; x.TransactionID ).Select(x =&gt; new ResultItem()
      {
       TransactionID = x.Key,
       SaleNumber = x.Sum(y =&gt; y.QuantityPurchased)                 
       })
       .ToList();
  </code></pre>
  
  <p>So as you can see I'm grouping by data in transactions table... Now what I would like to do here, if it's possible, in an easy manner to go across the User table into Items table and select a specific property that I need from it for that grouped item, which is CurrentPrice, and the table Transactions doesn't contains this data... </p>
  
  <p>So in the select statement I'd like to pull out the CurrentPrice property like this :</p>
  
  <pre><code>.Select(x =&gt; new ResultItem()
          {
           TransactionID = x.Key,
           SaleNumber = x.Sum(y =&gt; y.QuantityPurchased),
           CurrentPrice = // somehow go to Items table and pick up this data 
           })
           .ToList();
  </code></pre>
  
  <p>Can someone help me out ?</p>