src/ORM/Connect/PDOConnector.php
protected function prepareResults(PDOStatementHandle $statement, $errorLevel, $sql, $parameters = array())
    {

        // Catch error
        if ($this->hasError($statement)) {
            $this->lastStatementError = $statement->errorInfo();
            $statement->closeCursor();

            $this->databaseError($this->getLastError(), $errorLevel, $sql, $this->parameterValues($parameters));

            return null;
        }

        // Count and return results
        $this->rowCount = $statement->rowCount();
        return new PDOQuery($statement);
    }
protected function prepareResults(PDOStatementHandle $statement, $errorLevel, $sql, $parameters = array())
    {

        // Catch error
        if ($this->hasError($statement)) {
            $this->lastStatementError = $statement->errorInfo();
            $statement->closeCursor();

            $this->databaseError($this->getLastError(), $errorLevel, $sql, $this->parameterValues($parameters));

            return null;
        }

        // Count and return results
        $this->rowCount = $statement->rowCount();
        return new PDOQuery($statement);
    }
protected function prepareResults ( PDOStatementHandle $ statement , $ errorLevel , $ sql , $ parameters = array ( ) ) { // Catch error if ( $ this -> hasError ( $ statement ) ) { $ this -> lastStatementError = $ statement -> errorInfo ( ) ; $ statement -> closeCursor ( ) ; $ this -> databaseError ( $ this -> getLastError ( ) , $ errorLevel , $ sql , $ this -> parameterValues ( $ parameters ) ) ; return null ; } // Count and return results $ this -> rowCount = $ statement -> rowCount ( ) ; return new PDOQuery ( $ statement ) ; }
Given a PDOStatement that has just been executed, generate results
and report any errors

@param PDOStatementHandle $statement
@param int $errorLevel
@param string $sql
@param array $parameters
@return PDOQuery
Given a PDOStatement that has just been executed generate results and report any errors