title: Bulk insert with Doctrine 1.2
body: <p>This code (source: <a href="http://www.doctrine-project.org/documentation/manual/1_0/hu/component-overview:connection:flushing-the-connection" rel="nofollow">http://www.doctrine-project.org/documentation/manual/1_0/hu/component-overview:connection:flushing-the-connection</a>)</p>
  
  <pre><code>$conn = Doctrine_Manager::connection();
  
  $user1 = new User();
  $user1-&gt;username = 'Jack';
  
  $user2 = new User();
  $user2-&gt;username = 'jwage';
  
  $conn-&gt;flush();
  </code></pre>
  
  <p>is resulting 2 insert queries to be executed.</p>
  
  <p>Is there a way to do this with only one bulk insert?</p>
  
  <p>I think doctrine 2 is solving this problem (http://www.doctrine-project.org/blog/doctrine2-batch-processing), but it's still in beta. </p>
  
  <p>Any idea?</p>