Re: Can this query go faster??? - Mailing list pgsql-performance

From Csaba Nagy
Subject Re: Can this query go faster???
Date
Msg-id 1133872377.4779.200.camel@coppola.muc.ecircle.de
Whole thread Raw
In response to Re: Can this query go faster???  (Joost Kraaijeveld <J.Kraaijeveld@Askesis.nl>)
List pgsql-performance
On Tue, 2005-12-06 at 13:20, Joost Kraaijeveld wrote:
[snip]
> 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.

In this case the query will very likely not work faster. It must always
visit all the records till the required offset. If the plan should be
faster using the index, then you probably need to analyze (I don't
recall from your former posts if you did it recently or not), in any
case you could check an "explain analyze" to see if the planner is
mistaken or not - you might already know this.

Cheers,
Csaba.



pgsql-performance by date:

Previous
From: Jan Wieck
Date:
Subject: Re: Performance degradation after successive UPDATE's
Next
From: Ron
Date:
Subject: Re: Can this query go faster???