title: Inserting a row to a table with auto_increment column
body: <p>I'm working on a table that has 4 columns and the first one is an auto incrementing integer called id.</p>
  
  <p>If I'm going to insert into this table using mysqli prepared statements I keep having trouble inserting a query that works. Using phpMyAdmin It tells me to give it NULL. I've tried this:</p>
  
  <pre><code>$query = "INSERT INTO tbl (id, col2, col3, col4) VALUES ('NULL', ?, ?, ?)";
  $stmt -&gt; bind_param("ssi", $col2, $col3, $col4)
  </code></pre>
  
  <p>And this</p>
  
  <pre><code>$query = "INSERT INTO tbl (id, col2, col3, col4) VALUES (NULL, ?, ?, ?)";
  $stmt -&gt; bind_param("ssi", $col2, $col3, $col4)
  </code></pre>
  
  <p>And only give bind_param 3 arguments (the last 3). Neither of those work. I also tried this:</p>
  
  <pre><code>$null = NULL;
  $query = "INSERT INTO tbl (id, col2, col3, col4) VALUES (?, ?, ?, ?)";
  $stmt -&gt; bind_param("issi", $null, $col2, $col3, $col4);
  </code></pre>
  
  <p>None of these work. Is there a standardized way of inserting into this type of table?</p>