function StatementWrapper::setFetchMode
Same name and namespace in other branches
- 10 core/lib/Drupal/Core/Database/StatementWrapper.php \Drupal\Core\Database\StatementWrapper::setFetchMode()
File
-
core/
lib/ Drupal/ Core/ Database/ StatementWrapper.php, line 245
Class
- StatementWrapper
- Implementation of StatementInterface encapsulating PDOStatement.
Namespace
Drupal\Core\DatabaseCode
public function setFetchMode($mode, $a1 = NULL, $a2 = []) {
// Call \PDOStatement::setFetchMode to set fetch mode.
// \PDOStatement is picky about the number of arguments in some cases so we
// need to be pass the exact number of arguments we where given.
switch (func_num_args()) {
case 1:
return $this->clientStatement
->setFetchMode($mode);
case 2:
return $this->clientStatement
->setFetchMode($mode, $a1);
case 3:
default:
return $this->clientStatement
->setFetchMode($mode, $a1, $a2);
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.