You are viewing the PKP Support Forum | PKP Home Wiki

Resetting DAOResultFactory cursor to beginning of ResultSet

OJS development discussion, enhancement requests, third-party patches and plug-ins.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
Developer Resources:

Documentation: The OJS Technical Reference and the OJS API Reference are both available from the OJS Documentation page.

Git: You can access our public Git Repository here. Comprehensive Git usage instructions are available on the wiki.

Bugzilla: You can access our Bugzilla report tracker here.

Search: You can use our Google Custom Search to search across our main website, the support forum, and Bugzilla.

Questions and discussion are welcome, but if you have a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a technical support question, try the OJS Technical Support subforum.

Resetting DAOResultFactory cursor to beginning of ResultSet

Postby christo » Thu Oct 25, 2007 1:44 am


Is it possible to set the pointer back to the beginning of a resultset? sometihng similar to mysql_data_seek(0) ?
Posts: 22
Joined: Mon Jan 09, 2006 12:04 am
Location: Grahamstown, South Africa

Re: Resetting DAOResultFactory cursor to beginning of ResultSet

Postby asmecher » Thu Oct 25, 2007 9:27 am

Hi Christo,

Nothing in the current API, but it could probably added. Generally, if you need to seek through a ResultSet, I'd suggest converting it to an array (via the to_array function). The only down-side to this approach is the memory required to hold all elements in memory for large lists.

Alec Smecher
Public Knowledge Project Team
Posts: 10015
Joined: Wed Aug 10, 2005 12:56 pm

Return to OJS Development

Who is online

Users browsing this forum: No registered users and 2 guests