Commit eeac53e4 authored by Dries's avatar Dries
Browse files

- Patch #1266694 by Damien Tournoud: Fixed DatabaseStatementPrefetch doesn't...

- Patch #1266694 by Damien Tournoud: Fixed DatabaseStatementPrefetch doesn't implement fetchColumn().
parent 168c1364
......@@ -370,7 +370,7 @@ public function fetch($fetch_style = NULL, $cursor_orientation = PDO::FETCH_ORI_
}
}
public function fetchField($index = 0) {
public function fetchColumn($index = 0) {
if (isset($this->currentRow) && isset($this->columnNames[$index])) {
// We grab the value directly from $this->data, and format it.
$return = $this->currentRow[$this->columnNames[$index]];
......@@ -382,6 +382,10 @@ public function fetchField($index = 0) {
}
}
public function fetchField($index = 0) {
return $this->fetchColumn($index);
}
public function fetchObject($class_name = NULL, $constructor_args = array()) {
if (isset($this->currentRow)) {
if (!isset($class_name)) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment