diff --git a/dblayer.php b/dblayer.php index 455378a..15c3439 100644 --- a/dblayer.php +++ b/dblayer.php @@ -462,6 +462,11 @@ class dblayer extends PDO throw new Exception (dgettext("domframework", "The datas provided to create are not array"), 405); + foreach ($this->fields as $key=>$params) + { + if (in_array ("autoincrement", $params)) + $datas[$key] = null; + } if (!in_array ($this->primary, $this->unique)) $this->unique[] = $this->primary; $datasOK = array ();