diff -u b/core/lib/Drupal/Core/Cache/DatabaseBackend.php b/core/lib/Drupal/Core/Cache/DatabaseBackend.php --- b/core/lib/Drupal/Core/Cache/DatabaseBackend.php +++ b/core/lib/Drupal/Core/Cache/DatabaseBackend.php @@ -319,7 +319,7 @@ $cids = array_values(array_map(array($this, 'normalizeCid'), $cids)); // Update in chunks when a large array is passed. foreach (array_chunk($cids, 1000) as $cids_chunk) { - $this->connection->update($this->bin, ['on_table_missing' => FALSE]) + $this->connection->update($this->bin) ->fields(array('expire' => REQUEST_TIME - 1)) ->condition('cid', $cids_chunk, 'IN') ->execute(); diff -u b/core/lib/Drupal/Core/Config/DatabaseStorage.php b/core/lib/Drupal/Core/Config/DatabaseStorage.php --- b/core/lib/Drupal/Core/Config/DatabaseStorage.php +++ b/core/lib/Drupal/Core/Config/DatabaseStorage.php @@ -77,7 +77,7 @@ return (bool) $this->connection->queryRange('SELECT 1 FROM {' . $this->connection->escapeTable($this->table) . '} WHERE collection = :collection AND name = :name', 0, 1, array( ':collection' => $this->collection, ':name' => $name, - ), $this->options)->fetchField(); + ), $options)->fetchField(); } catch (\Exception $e) { // If we attempt a read without actually having the database or the table @@ -94,7 +94,7 @@ $options['on_table_missing'] = FALSE; $data = FALSE; try { - $raw = $this->connection->query('SELECT data FROM {' . $this->connection->escapeTable($this->table) . '} WHERE collection = :collection AND name = :name', array(':collection' => $this->collection, ':name' => $name), $this->options)->fetchField(); + $raw = $this->connection->query('SELECT data FROM {' . $this->connection->escapeTable($this->table) . '} WHERE collection = :collection AND name = :name', array(':collection' => $this->collection, ':name' => $name), $options)->fetchField(); if ($raw !== FALSE) { $data = $this->decode($raw); } @@ -114,7 +114,7 @@ $options['on_table_missing'] = FALSE; $list = array(); try { - $list = $this->connection->query('SELECT name, data FROM {' . $this->connection->escapeTable($this->table) . '} WHERE collection = :collection AND name IN (:names)', array(':collection' => $this->collection, ':names' => $names), $this->options)->fetchAllKeyed(); + $list = $this->connection->query('SELECT name, data FROM {' . $this->connection->escapeTable($this->table) . '} WHERE collection = :collection AND name IN (:names)', array(':collection' => $this->collection, ':names' => $names), $options)->fetchAllKeyed(); foreach ($list as &$data) { $data = $this->decode($data); } diff -u b/core/lib/Drupal/Core/Database/Query/Delete.php b/core/lib/Drupal/Core/Database/Query/Delete.php --- b/core/lib/Drupal/Core/Database/Query/Delete.php +++ b/core/lib/Drupal/Core/Database/Query/Delete.php @@ -145,7 +145,7 @@ try { return $this->connection->query((string) $this, $values, $this->queryOptions); } - catch (\PDOException $e) { + catch (\Exception $e) { if ($this->connection->isTableMissingException($e)) { // There are no rows to delete because the table doesn't exist so the // desired results are achieved. diff -u b/core/lib/Drupal/Core/Database/Query/Truncate.php b/core/lib/Drupal/Core/Database/Query/Truncate.php --- b/core/lib/Drupal/Core/Database/Query/Truncate.php +++ b/core/lib/Drupal/Core/Database/Query/Truncate.php @@ -66,7 +66,7 @@ try { return $this->connection->query((string) $this, array(), $this->queryOptions); } - catch (\PDOException $e) { + catch (\Exception $e) { if ($this->connection->isTableMissingException($e)) { // The table is quite empty. It doesn't even exist but that's fine. return 0; diff -u b/core/lib/Drupal/Core/Database/Query/Update.php b/core/lib/Drupal/Core/Database/Query/Update.php --- b/core/lib/Drupal/Core/Database/Query/Update.php +++ b/core/lib/Drupal/Core/Database/Query/Update.php @@ -208,7 +208,7 @@ try { return $this->doExecute(); } - catch (\PDOException $e) { + catch (\Exception $e) { if ($this->connection->isTableMissingException($e)) { // Every row (in the non-existing table, that is, so no rows) are // updated. diff -u b/core/tests/Drupal/Tests/Core/Database/Stub/StubConnection.php b/core/tests/Drupal/Tests/Core/Database/Stub/StubConnection.php --- b/core/tests/Drupal/Tests/Core/Database/Stub/StubConnection.php +++ b/core/tests/Drupal/Tests/Core/Database/Stub/StubConnection.php @@ -75,9 +75,7 @@ } /** - * Determines whether an exception means missing table. - * @param $sqlstate - * @param \PDOException $e + * {@inheritdoc} */ public function isTableMissingException(\Exception $e) { }