title: How to join two tables, and retrieve item collection using Linq
body: <p>I have two tables: baswareCatalog.FlowCurrent and baswareCatalog.Doc.
  They both contain the attribute DocId.
  The Doc-table also has the attributes LastExpireDate and Status.
  FlowCurrent-table also has the attribute RecipientName.
  I want to retrieve a collection of Doc, where the DocId of the item is the same in both tables.</p>
  
  <p>Furthermore, this condition must be true: flowCurrent.RecipientName.Contains(userFullName)</p>
  
  <p>I tried the following, but I don’t know if it is correct.</p>
  
  <pre><code>var docitemIQueryable = from flowCurrent in baswareCatalog.FlowCurrent join 
                          document in baswareCatalog.Docs on 
                          flowCurrent.DocId equals document.DocId 
                          where flowCurrent.RecipientName.Contains(userFullName) 
                          select new
                          {
                            Items = baswareCatalog
                                    .Docs
                                    .Where(b =&gt; b.DocId == flowCurrent.DocId)
                          };
  </code></pre>
  
  <p>The return-value is </p>
  
  <pre><code>'interface System.Linq.IQueryable&lt;out T&gt;'.
  T is 'a' 
  Anonymous Types: 'a is new {IQueryable&lt;Doc&gt; Items }'
  </code></pre>
  
  <p>How do I retrieve a collection of Doc that I can iterate over?</p>