title: Using custom methods in linq to entities
body: <p>I have a <code>Person</code> table in my database that has <code>NationalId</code> field.
  Is there any way to load all Persons with even <code>NationalId</code>, using <code>Ef code first</code> and <code>Linq to entities</code>, without loading all <code>Person</code>s to memory?</p>
  
  <p>Somethings like:</p>
  
  <pre><code>public  bool IsEven(int number)
  {
     return number % 2 == 0;
  }
  
  var context = new MyContext();
  var personsWithEvenNationalId = context.Persons
                                         .Where(x=&gt; IsEven(x.NationalId))
                                         .ToList();
  </code></pre>