Re: [GENERAL] Row Count?

Поиск
Список
Период
Сортировка
От Bruce Tong
Тема Re: [GENERAL] Row Count?
Дата
Msg-id Pine.LNX.4.04.9905051135530.20368-100000@laxmi.ev.net
обсуждение исходный текст
Ответ на Re: [GENERAL] Row Count?  (Thomas Reinke <reinke@e-softinc.com>)
Список pgsql-general
> > SELECT * FROM foo WHERE ROW_COUNT < 10;
> > Is there anything like "ROW_COUNT" or "ROWCOUNT" in PostgreSQL?

> If trying to receive 10 rows, try
>
> begin;
> declare thomas cursor for select * from foo;
> fetch 10 in thomas;
> end;

Ooo, a cursor. I'll have to look into those. I was thinking I could just
issue "select * from foo" and then only use the first 10 results, but that
seemed like such a waste of time since there's likely to be 100's of
records. Admittedly I'm ignorant of the solution you pose and I'll have to
do some research, but it seems it too might also have the postmaster
return all of the records, of which I would only use 10. Am I wrong?


Bruce Tong                 |  Got me an office; I'm there late at night.
Systems Programmer         |  Just send me e-mail, maybe I'll write.
Electronic Vision / FITNE  |
zztong@laxmi.ev.net        |  -- Joe Walsh for the 21st Century



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

Предыдущее
От: Thomas Reinke
Дата:
Сообщение: Re: [GENERAL] Row Count?
Следующее
От: "Wim Ceulemans"
Дата:
Сообщение: Re: [GENERAL] Row Count?