Re: Query uses incorrect index

From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: <pasman(dot)p(at)gmail(dot)com>,<gc(at)mnc(dot)ch>
Cc: <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Query uses incorrect index
Date: 2010-12-22 12:31:28
Message-ID: 4D119B40020000250003892D@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Guillaume Cottenceau wrote:

> If I'm correct, you're basically telling postgresql that your
> disk is unusually fast compared to your CPU. Even if some queries
> will run faster from a side-effect of these settings, you're
> likely to create other random problems...

If this is set globally and the active portion of the database is not
highly cached, yes. If the example query is typical of the level of
caching for frequently-run queries, it might provide an overall
performance boost to set these in postgresql.conf.

The original problem was that the optimizer was grossly
over-estimating the cost of returning a tuple through the index,
which was taking about 0.01 ms per tuple.

-Kevin

Browse pgsql-performance by date

  From Date Subject
Next Message Tom Lane 2010-12-22 15:19:28 Re: Query uses incorrect index
Previous Message Gurjeet Singh 2010-12-22 12:13:56 Re: PostgreSQL 9.0 x64 bit pgbench TPC very low question?