title: PDO not inserting - no error
body: <p>I do not understand why these lines do not work:</p>
  
  <pre><code>  $host = 'localhost';
    $dbname='mydbname';
    $login='mylogin';
    $pwd='mypwd';
    $datex = date('Y/m/d H:i:s');
    $nomx = 'jrmy';
    $numx = '007';
    try {
      $bdd = new PDO('mysql:host='.$host.';dbname='.$dbname, $login, $pwd);
    }
    catch(Exception $e) {
      die('Erreur : '.$e-&gt;getMessage());
    }
    $bdd-&gt;exec('INSERT INTO dossiers(date, nom, numero, disp) VALUES(\''.$datex.'\', \''.$nomx.'\', \''.$numx.'\', \'Y\')');
    $id = $bdd-&gt;lastInsertId();
    $bdd= null;
    echo 'id: '.$id;
  </code></pre>
  
  <p>disclosure: the script worked on my apache server, and since I installed my script on a IIS server it stopped working...</p>
  
  <p>AND the query function works perfectly... query OK, insert NO</p>
  
  <p>EDIT : thank you all! really!</p>