mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
Correctly identifier quote column names before adding them to queries.
Closes #2248
This commit is contained in:
parent
927a4933d1
commit
9e4ac31dc3
1 changed files with 1 additions and 0 deletions
|
@ -325,6 +325,7 @@ class Postgres extends DboSource {
|
|||
$fullTable = $this->fullTableName($table);
|
||||
|
||||
$sequence = $this->value($this->getSequence($tableName, $column));
|
||||
$column = $this->name($column);
|
||||
$this->execute("SELECT setval($sequence, (SELECT MAX($column) FROM $fullTable))");
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue