You are here

public function Connection::NotifyException in Drupal driver for SQL Server and SQL Azure 8.2

Only to be used by statements to notify of a PDO exception.

Parameters

\PDOException $e:

3 calls to Connection::NotifyException()
Connection::exec in drivers/lib/Drupal/Driver/Database/sqlsrv/PDO/Connection.php
{@inhertidoc}
Connection::query in drivers/lib/Drupal/Driver/Database/sqlsrv/PDO/Connection.php
Connection::query_execute in drivers/lib/Drupal/Driver/Database/sqlsrv/PDO/Connection.php
Custom function to easy querying data without needing to prepare.

File

drivers/lib/Drupal/Driver/Database/sqlsrv/PDO/Connection.php, line 224

Class

Connection

Namespace

Drupal\Driver\Database\sqlsrv\PDO

Code

public function NotifyException(\PDOException $e) {

  // Protection against issue of PDO driver.
  if ($this->in_transaction) {

    // Some PDO exceptions are "safe" and will not doom the
    // transaction.
    if (!isset($this->allowed_pdo_exception_codes[$e
      ->getCode()])) {
      $this->doomed_transaction = true;
      $this->doomed_transaction_exception = $e;
    }
  }
}