Pagination - 1 or 2 queries?

Поиск
Список
Период
Сортировка
От CSN
Тема Pagination - 1 or 2 queries?
Дата
Msg-id 20030905091734.23356.qmail@web40612.mail.yahoo.com
обсуждение исходный текст
Ответы Re: Pagination - 1 or 2 queries?  ("scott.marlowe" <scott.marlowe@ihs.com>)
Список pgsql-general
Since you usually need to know the total number of
rows a query would return, do you think it's better
to:

a) Do one query with a LIMIT and OFFSET to get the
results, and another COUNT query to get the total
number of rows?

b) Do a single query without a LIMIT and OFFSET, then
do a seek or similiar to get at the rows you want?

Most tutorials, code, etc. I've seen do "a". The
eclipse library does "b".


__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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

Предыдущее
От: psql-mail@freeuk.com
Дата:
Сообщение: Re: postmaster crashing
Следующее
От: "Amin Schoeib"
Дата:
Сообщение: Problem with to_date/to_char