// fails. This is important for tables that are created on demand. For
// example, \Drupal\Core\Cache\DatabaseBackend.
$this->connection->
addSavepoint();
try { $stmt->
execute(NULL,
$this->queryOptions
);
if (isset($table_information->serial_fields
[0
])) { $last_insert_id =
$stmt->
fetchField();
} $this->connection->
releaseSavepoint();
} catch (\Exception
$e) { $this->connection->
rollbackSavepoint();
$this->connection->
exceptionHandler()->
handleExecutionException($e,
$stmt,
[],
$this->queryOptions
);
} // Re-initialize the values array so that we can re-use this query.
$this->insertValues =
[];
return $last_insert_id ?? NULL;
} public function __toString() { // Create a sanitized comment string to prepend to the query.