Can I do of in one call?

Поиск
Список
Период
Сортировка
От Rory Campbell-Lange
Тема Can I do of in one call?
Дата
Msg-id 20030616164354.GA4515@campbell-lange.net
обсуждение исходный текст
Список pgsql-general
I am writing a function to interrogate the database and get a total row
count of rows matching the critera of a search, and then return a subset
of those rows. This is to satisfy the familiar  web <page> of <pages>
situation.

At the moment I call the query twice, one with limit and offset
statements, the other without these. I use ROW_COUNT after the second.

Is it possible to do a query, get the ROW_COUNT, and then use a cursor
or something similar to get the subset into a setof result%rowtype?

Thanks!
Rory

--
Rory Campbell-Lange
<rory@campbell-lange.net>
<www.campbell-lange.net>

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

Предыдущее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: Sort memory not being released
Следующее
От: Arjen van der Meijden
Дата:
Сообщение: Re: Postgres performance comments from a MySQL user