Re: Number of rows in a cursor ?

Поиск
Список
Период
Сортировка
От Michael Fuhr
Тема Re: Number of rows in a cursor ?
Дата
Msg-id 20050824131921.GA39444@winnie.fuhr.org
обсуждение исходный текст
Ответ на Re: Number of rows in a cursor ?  (Bo Lorentsen <bl@netgroup.dk>)
Ответы Re: Number of rows in a cursor ?  (Bo Lorentsen <bl@netgroup.dk>)
Список pgsql-sql
On Wed, Aug 24, 2005 at 02:50:07PM +0200, Bo Lorentsen wrote:
> Russell Simpkins wrote:
> >If you need a count, why not just execute one of the methods to get a 
> >count. i.e.e select count(id) ...
> 
> The reason why i don't  just make a count and then a selection of data 
> is performance.

...which is the same reason a cursor doesn't know how many rows it will
fetch until you fetch them all (or MOVE to the end of the cursor,
which fetches the rows internally).

-- 
Michael Fuhr


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

Предыдущее
От: Bo Lorentsen
Дата:
Сообщение: Re: Number of rows in a cursor ?
Следующее
От: Josep Sanmartí
Дата:
Сообщение: How to join several selects