function StringDatabaseStorage::dbDelete
Same name in other branches
- 8.9.x core/modules/locale/src/StringDatabaseStorage.php \Drupal\locale\StringDatabaseStorage::dbDelete()
- 10 core/modules/locale/src/StringDatabaseStorage.php \Drupal\locale\StringDatabaseStorage::dbDelete()
- 11.x core/modules/locale/src/StringDatabaseStorage.php \Drupal\locale\StringDatabaseStorage::dbDelete()
Creates delete query.
Parameters
string $table: The table name.
array $keys: Array with object keys indexed by field name.
Return value
\Drupal\Core\Database\Query\Delete Returns a new Delete object for the injected database connection.
File
-
core/
modules/ locale/ src/ StringDatabaseStorage.php, line 526
Class
- StringDatabaseStorage
- Defines a class to store localized strings in the database.
Namespace
Drupal\localeCode
protected function dbDelete($table, $keys) {
$query = $this->connection
->delete($table, $this->options);
foreach ($keys as $field => $value) {
$query->condition($field, $value);
}
return $query;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.