title: MySQL Bulk Insert Ignore
body: <p>I've a few questions regarding the MySQL bluk insert Ignore statement, both for InnoDB and MyISAM.An example:</p>
  
  <pre><code>INSERT IGNORE INTO table(`reference`) VALUES ('1','2','3')
  </code></pre>
  
  <p>Reference is an unique key also.</p>
  
  <ol>
  <li><p>Is a bulk insert atomic? So if I send this to the database can I be assured that no other inserts occur in between this statement?</p></li>
  <li><p>A batch insert returns the value of the First ID inserted of the batch. However, what happens if the first insert happens to be a duplicate (do I get a 0 as a return value or is the next (successful insert returned, I couldn't find this in the docs)</p></li>
  </ol>
  
  <p>Kind regards,</p>