title: How to Delete multiple records in Linq to Entity?
body: <p>I have a tblA in sql:</p>
  
  <pre><code>id  int  (primary key)
  fid  int 
  </code></pre>
  
  <p>data in tblA is:</p>
  
  <pre><code>1   1
  2   1
  3   2
  4   2
  5   3
  6   3
  </code></pre>
  
  <p>i delete <strong>one record</strong> by following code:</p>
  
  <pre><code>DatabaseEntities obj = new DatabaseEntities();
  int i = 2;
  tblA t = obj.tblA.Where(x =&gt; x.fid == i).FirstOrDefault();
  obj.DeleteObject(t);
  obj.SaveChanges();
  </code></pre>
  
  <p>i delete multiple records by following code:</p>
  
  <pre><code>DatabaseEntities obj = new DatabaseEntities();
  int i = 2;
  while (obj.tblA.Where(x =&gt; x.fid == i).Count() != 0)
  {
     tblA t = obj.tblA.Where(x =&gt; x.fid == i).FirstOrDefault();
     obj.DeleteObject(t);
     obj.SaveChanges();
  }
  </code></pre>
  
  <p>Is there any solution for delete <strong>multiple records</strong> in linq to entity?</p>