dblayeroo: pgsql doesn't supports lastInsertId if there is no autoincrement field

git-svn-id: https://svn.fournier38.fr/svn/ProgSVN/trunk@3919 bf3deb0d-5f1a-0410-827f-c0cc1f45334c
This commit is contained in:
2017-09-04 13:46:20 +00:00
parent 82b25ae519
commit fdce871157

View File

@@ -2767,6 +2767,8 @@ class dblayeroo
$sql = $this->createRequest ();
if ($this->driver === "pgsql" && $this->command === "INSERT")
{
// PgSQL doesn't support the lastInsertId if there is no autoincrement
// field. Will return the primary key
$sql .= " RETURNING ".$this->sep.$this->primary.$this->sep;
}
$this->debugLog ("Entering prepareRequest (XXX, ",false,")");