Permalink
Browse files

Implement columnCount function in AkibanSrvStatement class.

  • Loading branch information...
1 parent 68dc30d commit 44bbb0f7389afde71045cfb1222cc99535a66e4b @posulliv committed Aug 14, 2012
Showing with 4 additions and 4 deletions.
  1. +4 −4 lib/Doctrine/DBAL/Driver/AkibanSrv/AkibanSrvStatement.php
@@ -127,7 +127,10 @@ public function closeCursor()
*/
public function columnCount()
{
- // TODO
+ if ($this->_results) {
+ return pg_num_fields($this->_results);
+ }
+ return 0;
}
/**
@@ -151,9 +154,6 @@ public function errorInfo()
*/
public function execute($params = null)
{
- if (is_null($params)) {
- $args = array();
- }
if (empty($this->_parameters) && is_null($params)) {
$this->_results = pg_query($this->_dbh, $this->_statement);
} else if (empty($this->_parameters) && ! is_null($params)) {

0 comments on commit 44bbb0f

Please sign in to comment.