You are here

public static function Utils::BindArguments in Drupal driver for SQL Server and SQL Azure 8

Same name and namespace in other branches
  1. 3.0.x drivers/lib/Drupal/Driver/Database/sqlsrv/Utils.php \Drupal\Driver\Database\sqlsrv\Utils::bindArguments()

Summary of BindArguments

Parameters

PDOStatement $stmt:

array $values:

2 calls to Utils::BindArguments()
Insert::execute in drivers/lib/Drupal/Driver/Database/sqlsrv/Insert.php
Executes the insert query.
Update::execute in drivers/lib/Drupal/Driver/Database/sqlsrv/Update.php
Executes the UPDATE query.

File

drivers/lib/Drupal/Driver/Database/sqlsrv/Utils.php, line 22

Class

Utils

Namespace

Drupal\Driver\Database\sqlsrv

Code

public static function BindArguments(\PDOStatement $stmt, array &$values) {
  foreach ($values as $key => &$value) {
    $stmt
      ->bindParam($key, $value, PDO::PARAM_STR);
  }
}