mirror of
https://github.com/moodle/moodle.git
synced 2025-08-02 15:49:43 +02:00
MDL-17378 DML: fixed pg < 8.3 regression - found by sam, thanks
This commit is contained in:
parent
7fdcb77942
commit
d55132a769
1 changed files with 1 additions and 1 deletions
|
@ -674,7 +674,7 @@ class pgsql_native_moodle_database extends moodle_database {
|
||||||
unset($params['id']);
|
unset($params['id']);
|
||||||
} else {
|
} else {
|
||||||
//ugly workaround for pg < 8.2
|
//ugly workaround for pg < 8.2
|
||||||
$seqsql = "SELECT NEXTVAL({$this->prefix}{$table}_id_seq) AS id";
|
$seqsql = "SELECT NEXTVAL('{$this->prefix}{$table}_id_seq') AS id";
|
||||||
$this->query_start($seqsql, NULL, SQL_QUERY_AUX);
|
$this->query_start($seqsql, NULL, SQL_QUERY_AUX);
|
||||||
$result = pg_query($this->pgsql, $seqsql);
|
$result = pg_query($this->pgsql, $seqsql);
|
||||||
$this->query_end($result);
|
$this->query_end($result);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue