Thank you - On Fri, Oct 14, 2011 at 11:30 AM, Pavel Stehule <pavel.stehule@xxxxxxxxx> wrote: > you should to use a DECLARE statement > http://www.postgresql.org/docs/9.1/interactive/sql-declare.html > and fetch statement > http://www.postgresql.org/docs/9.1/interactive/sql-fetch.html I've managed to create a cursor and can fetch the data row by row: quincy=> start TRANSACTION; quincy=> declare XXX cursor for select to_char(qdatetime, 'YYYY-MM-DD') as QDATETIME,ID,NAME,CATEGORY,APPSVERSION,OSVERSION,DETAILS,DEVINFO from quincyview where qdatetime <= now() order by QDATETIME desc ; quincy=> fetch XXX; ..... quincy=> fetch XXX; ..... But how do I "go back"? For my jQuery HTML table (DataTables.net) I need to be able to go back and forth. Regards Alex -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general