Re: Can this query go faster???

From: Joost Kraaijeveld <J(dot)Kraaijeveld(at)Askesis(dot)nl>
To: Tino Wildenhain <tino(at)wildenhain(dot)de>
Cc: Csaba Nagy <nagy(at)ecircle-ag(dot)com>, Pgsql-Performance <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Can this query go faster???
Date: 2005-12-06 12:20:45
Message-ID: 1133871645.8837.78.camel@Panoramix
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Tue, 2005-12-06 at 12:36 +0100, Tino Wildenhain wrote:
> >
> > I just tried it: a cursor is not faster (what does not surprise me at
> > all, as the amount of work looks the same to me)
>
> Actually no, if you scroll forward, you just ask the database for the
> next rows to materialize. So if you are ahead in your database and
> ask for next rows, it should be faster then working w/ an offset
> from start each time.
Ah, a misunderstanding: I only need to calculate an index if the user
wants a record that is not in or adjacent to the cache (in which case I
can do a "select values > last value in the cache". So I must always
materialize all rows below the wanted index.

--
Groeten,

Joost Kraaijeveld
Askesis B.V.
Molukkenstraat 14
6524NB Nijmegen
tel: 024-3888063 / 06-51855277
fax: 024-3608416
e-mail: J(dot)Kraaijeveld(at)Askesis(dot)nl
web: www.askesis.nl

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Tino Wildenhain 2005-12-06 12:30:25 Re: Can this query go faster???
Previous Message David Lang 2005-12-06 11:39:41 Re: BLCKSZ