title: LINQ to Entities does not recognize the method
body: <pre><code>public IQueryable&lt;Product&gt; GetModelsInBrand(int BrandId) 
  { 
      IQueryable&lt;Product&gt; query = 
           from Product 
            in ObjectContext.Products.Where(p =&gt; (p.BrandId == BrandId)) 
           orderby Product.Model 
           select Product; 
          query = query.Distinct(new ProductByModelEqualityComparer()); 
          return query; 
  }
  </code></pre>
  
  <p>After return query was executed, I got </p>
  
  <blockquote>
    <p>Load operation failed for query 'GetModelsInBrand'.  LINQ to Entities does not recognize the method."   </p>
  </blockquote>
  
  <p>Can anyone help to correct it?</p>