Re: Fun with Cursors- how to rewind a cursor

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Fun with Cursors- how to rewind a cursor
Дата
Msg-id 28067.1172797492@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Fun with Cursors- how to rewind a cursor  ("Postgres User" <postgres.developer@gmail.com>)
Ответы Re: Fun with Cursors- how to rewind a cursor  ("Postgres User" <postgres.developer@gmail.com>)
Список pgsql-general
"Postgres User" <postgres.developer@gmail.com> writes:
> Is there any way to 'rewind' the cursor to the first row?

plpgsql doesn't have any command for that (though I think someone is
working on improving its cursor command set).  You should be able to
work around it by EXECUTE'ing a MOVE BACKWARD ALL command, though.
You just need to know the real name of the cursor --- see 'Returning
Cursors' in the plpgsql docs for discussion.

            regards, tom lane

В списке pgsql-general по дате отправления:

Предыдущее
От: Demian Lessa
Дата:
Сообщение: Constraint validation
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Constraint validation