Re: [HACKERS] What about LIMIT in SELECT ?

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: [HACKERS] What about LIMIT in SELECT ?
Дата
Msg-id 199810132118.RAA11266@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: [HACKERS] What about LIMIT in SELECT ?  ("Marc G. Fournier" <scrappy@hub.org>)
Ответы Re: [HACKERS] What about LIMIT in SELECT ?
Re: [HACKERS] What about LIMIT in SELECT ?
Список pgsql-hackers
> Ookay, I'm sorry, butyou lost me here.  I haven't gotten into using
> CURSORs/FETCHs yet, since I haven't need it...but can you give an example
> of what you would want to do using a LIMIT?  I may be missing something,
> but wha is the different between using LIMIT to get X records, and
> definiing a cursor to FETCH X records?
>
> Practical example of *at least* the LIMIT side would be good, so that we
> can at least see a physical example of what LIMIT can do that
> CURSORs/FETCH can't...

My guess in a web application is that the transaction is started for
every new page, so you can't have transactions spanning SQL sessions.

LIMIT theoretically would allow you to start up where you left off.

--
  Bruce Momjian                        |  http://www.op.net/~candle
  maillist@candle.pha.pa.us            |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026


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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: [HACKERS] What about LIMIT in SELECT ?
Следующее
От: "Marc G. Fournier"
Дата:
Сообщение: Re: [ADMIN] COPY slows down; is it normal?