title: MySQL/PHP mass delete using array: Best method?
body: <p>I need to do a mass delete from a MySQL table via PHP (using PDO).  The table has a field called 'id' and all the id's to be deleted are stored in an array.  There may be 5 rows to delete from the table or there may be 5000+.</p>
  
  <p>My immediate thought is to use a foreach and iterate through the array deleting one at time.  However something tells me that may not be a very good method if there are a lot of elements in the array.</p>
  
  <p>Any thoughts on a best method for doing this type of delete?</p>