title: MySQL- Insert a record with empty primary key, works on one server, not the other
body: <p>I have a table in a MySQL Server (version 5.5.27, installed with EasyPHP for development), it has an ID with Auto_Increment, and it's data type is INT(11).</p>
  
  <p>When i try to insert a record, using this statement, it works. </p>
  
  <pre><code>insert into factclientes (IDFactClientes, IDTercero, SubTotal, IVA, Total)
          values ('', '3', '2500.00', '400.00', '2900.00')
          ON DUPLICATE KEY UPDATE IDTercero = values(IDTercero),
                  SubTotal = values(SubTotal), 
                  IVA = values(IVA), 
                  Total = values(Total)
  </code></pre>
  
  <p>But when i try to insert that same record on my production server (version 5.6.17, installed independently on another machine) it throws an error:</p>
  
  <pre><code> Incorrect integer value: '' for column 'IDFactClientes' at row 1
  </code></pre>
  
  <p>I know it is because the primary key ID 'IDFactClientes' has an empty value.  I do this because i use the same statement to INSERT and to UPDATE. If my program doesn't know and doesn't specify the IDFactClientes, i want a new record, if my program knows the ID already, and it's specified i want the record to be updated.</p>
  
  <p>The weird thing is that it works on my dev machine, but it doesn't on my production server.</p>
  
  <p>Is there a setting im missing?? how could i fix this??  i have the exact same problem with all the tables of my database and i wouldn't want to modify all the statements in my program... if it's possible</p>
  
  <p>Thank you in advance!!</p>