title: Using Find in CodeFirst (EntityFramework) to get non-primary keys
body: <p>My understanding is that find only takes the primary key as the parameter. That works great if the value you are looking for is actually the primary key. In my case, I have a class like this:</p>
  
  <pre><code> public class Chamber
   {
      [Key]
      public int Id {get;set;}
  
      public string ChamberName { get; set; }
   }
  </code></pre>
  
  <p>I want to check whether a given <code>ChamberName</code> exists in either my context or the database itself. How can I do that? Do I have to somehow enumerate of the context myself first, then, look it up in the database with a call like <code>db.Chambers.where(a=&gt;a.ChamberName.equals...</code>?</p>
  
  <p>I can see it working well if <code>ChamberName</code> is my primary key, but it is not.</p>
  
  <p>THanks,</p>