Db\Result\Pdo::fetch

public fetch ([mixed $fetchStyle], [mixed $cursorOrientation], [mixed $cursorOffset]) Fetches an array/object of strings that corresponds to the fetched row, or FALSE if there are no more rows. This method is affected by the active fetch flag set using Phalcon\Db\Result\Pdo::setFetchMode $result = $connection->query("SELECT * FROM robots ORDER BY name"); $result->setFetchMode(Phalcon\Db::FETCH_OBJ); while ($robot = $result->fetch()) { echo $robot->name; }

Db\Result\Pdo::execute

public execute () Allows to execute the statement again. Some database systems don’t support scrollable cursors, So, as cursors are forward only, we need to execute the cursor again to fetch rows from the begining

Db\Result\Pdo::dataSeek

public dataSeek (mixed $number) Moves internal resultset cursor to another position letting us to fetch a certain row $result = $connection->query("SELECT * FROM robots ORDER BY name"); $result->dataSeek(2); // Move to third row on result $row = $result->fetch(); // Fetch third row

Db\Result\Pdo

implements Phalcon\Db\ResultInterface Source on GitHub Encapsulates the resultset internals $result = $connection->query("SELECT * FROM robots ORDER BY name"); $result->setFetchMode(Phalcon\Db::FETCH_NUM); while ($robot = $result->fetchArray()) { print_r($robot); } Methods public __construct (Phalcon\Db\AdapterInterface $connection, PDOStatement $result, [string $sqlStatement], [array $bindParams], [array $bindTypes]) Phalcon\Db\Result\Pdo constructor public execute () Allows to e

Db\ResultInterface::setFetchMode

abstract public setFetchMode (mixed $fetchMode) ...

Db\ResultInterface::numRows

abstract public numRows () ...

Db\ResultInterface::getInternalResult

abstract public getInternalResult () ...

Db\ResultInterface::fetchArray

abstract public fetchArray () ...

Db\ResultInterface::fetchAll

abstract public fetchAll () ...

Db\ResultInterface::fetch

abstract public fetch () ...