function Merge::isNativeMerge
Determines whether the query executes as a single native MERGE statement.
The native MERGE statement can only be used when the condition targets the merge table itself and when there is something to insert. In all other cases the generic SELECT + INSERT/UPDATE emulation is used.
Return value
bool TRUE if the query executes as a native MERGE statement, FALSE if it uses the generic emulation.
2 calls to Merge::isNativeMerge()
- Merge::execute in core/
modules/ pgsql/ src/ Driver/ Database/ pgsql/ Merge.php - Executes the merge database query.
- Merge::__toString in core/
modules/ pgsql/ src/ Driver/ Database/ pgsql/ Merge.php - Implements PHP magic __toString method to convert the query to a string.
File
-
core/
modules/ pgsql/ src/ Driver/ Database/ pgsql/ Merge.php, line 79
Class
- Merge
- PostgreSQL implementation of \Drupal\Core\Database\Query\Merge.
Namespace
Drupal\pgsql\Driver\Database\pgsqlCode
protected function isNativeMerge() : bool {
return $this->conditionTable === $this->table && ($this->insertFields || $this->defaultFields);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.