От: mark@mark.mielke.cc
Тема: Re: Suspending SELECTs
Дата: ,
Msg-id: 20060117211259.GA13926@mark.mielke.cc
(см: обсуждение, исходный текст)
Ответ на: Re: Suspending SELECTs  (Alessandro Baretta)
Ответы: Re: Suspending SELECTs  (Frank Wiles)
Re: Suspending SELECTs  (Mark Kirkwood)
Re: Suspending SELECTs  (Alessandro Baretta)
Список: pgsql-performance

Скрыть дерево обсуждения

Suspending SELECTs  (Alessandro Baretta, )
 Re: Suspending SELECTs  (Tom Lane, )
  Re: Suspending SELECTs  (Alvaro Herrera <-ip.org>, )
   Re: Suspending SELECTs  (Tom Lane, )
  Re: Suspending SELECTs  ("Craig A. James", )
   Re: Suspending SELECTs  (Alessandro Baretta, )
    Re: Suspending SELECTs  ("Jim C. Nasby", )
    Re: Suspending SELECTs  (Mark Lewis, )
    Re: Suspending SELECTs  ("Craig A. James", )
  Re: Suspending SELECTs  (Alessandro Baretta, )
   Re: Suspending SELECTs  (Michael Stone, )
   Re: Suspending SELECTs  (Tom Lane, )
   Re: Suspending SELECTs  (, )
    Re: Suspending SELECTs  (Frank Wiles, )
    Re: Suspending SELECTs  (Mark Kirkwood, )
     Re: Suspending SELECTs  (Tom Lane, )
      Re: Suspending SELECTs  (Mark Kirkwood, )
    Re: Suspending SELECTs  (Alessandro Baretta, )
     Re: Suspending SELECTs  (Tino Wildenhain, )
     Re: Suspending SELECTs  (, )
      Re: Suspending SELECTs  (Alessandro Baretta, )
       Re: Suspending SELECTs  (Harry Jackson, )
        Re: Suspending SELECTs  (, )
   Re: Suspending SELECTs  (Josh Berkus, )
    Re: Suspending SELECTs  (Josh Berkus, )
     Re: Suspending SELECTs  (Alessandro Baretta, )
      Re: Suspending SELECTs  (August Zajonc, )
       Re: Suspending SELECTs  (Alessandro Baretta, )
 Re: Suspending SELECTs  (Mark Lewis, )

On Tue, Jan 17, 2006 at 08:56:00PM +0100, Alessandro Baretta wrote:
> I understand most of these issues, and expected this kind of reply. Please,
> allow me to insist that we reason on this problem and try to find a
> solution. My reason for doing so is that the future software industry is
> likely to see more and more web applications retrieving data from virtually
> endless databases, and in such contexts, it is sensible to ask the final
> client--the web client--to store the "cursor state", because web
> interaction is intrinsically asynchronous, and you cannot count on users
> logging out when they're done, releasing resources allocated to them. Think
> of Google.

What is wrong with LIMIT and OFFSET? I assume your results are ordered
in some manner.

Especially with web users, who become bored if the page doesn't flicker
in a way that appeals to them, how could one have any expectation that
the cursor would ever be useful at all?

As a 'general' solution, I think optimizing the case where the same
query is executed multiple times, with only the LIMIT and OFFSET
parameters changing, would be a better bang for the buck. I'm thinking
along the lines of materialized views, for queries executed more than
a dozen times in a short length of time... :-)

In the mean time, I successfully use LIMIT and OFFSET without such an
optimization, and things have been fine for me.

Cheers,
mark

--
 /  /      __________________________
.  .  _  ._  . .   .__    .  . ._. .__ .   . . .__  | Neighbourhood Coder
|\/| |_| |_| |/    |_     |\/|  |  |_  |   |/  |_   |
|  | | | | \ | \   |__ .  |  | .|. |__ |__ | \ |__  | Ottawa, Ontario, Canada

  One ring to rule them all, one ring to find them, one ring to bring them all
                       and in the darkness bind them...

                           http://mark.mielke.cc/



В списке pgsql-performance по дате сообщения:

От: Mark Kirkwood
Дата:
Сообщение: Re: Suspending SELECTs
От: Hari Warrier
Дата:
Сообщение: Getting pg to use index on an inherited table (8.1.1)