public static function Utils::bindArguments in Drupal driver for SQL Server and SQL Azure 3.0.x
Same name and namespace in other branches
- 8 drivers/lib/Drupal/Driver/Database/sqlsrv/Utils.php \Drupal\Driver\Database\sqlsrv\Utils::BindArguments()
Bind the arguments to the statement.
Parameters
\PDOStatement $stmt: Statement.
array $values: Argument values.
2 calls to Utils::bindArguments()
- Insert::execute in drivers/
lib/ Drupal/ Driver/ Database/ sqlsrv/ Insert.php - Runs the query against the database.
- 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 20
Class
- Utils
- Utility function for the SQL Server driver.
Namespace
Drupal\Driver\Database\sqlsrvCode
public static function bindArguments(\PDOStatement $stmt, array &$values) {
foreach ($values as $key => &$value) {
$stmt
->bindParam($key, $value, \PDO::PARAM_STR);
}
}