You are here

public static function DatabaseUtils::BindArguments in Drupal driver for SQL Server and SQL Azure 7.2

Same name and namespace in other branches
  1. 7.3 sqlsrv/utils.inc \DatabaseUtils::BindArguments()

Summary of BindArguments

Parameters

PDOStatement $stmt:

array $values:

3 calls to DatabaseUtils::BindArguments()
InsertQuery_sqlsrv::execute in sqlsrv/query.inc
Executes the insert query.
MergeQuery_sqlsrv::execute in sqlsrv/query.inc
Runs the query against the database.
UpdateQuery_sqlsrv::execute in sqlsrv/query.inc
Executes the UPDATE query.

File

sqlsrv/utils.inc, line 9

Class

DatabaseUtils

Code

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