Re: Bad planner decision - bitmap scan instead of index

From: Frank Schoep <frank(at)ffnn(dot)nl>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: Bad planner decision - bitmap scan instead of index
Date: 2007-08-16 19:25:14
Message-ID: C96EA746-535E-40FE-9249-37C3F57459BC@ffnn.nl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Aug 16, 2007, at 7:01 PM, Tom Lane wrote:
> …
> Why is the sort step so slow? Sorting a mere 13k rows shouldn't take
> very long. Maybe you are overrunning work_mem and it's falling back
> to a disk sort ... what is work_mem set to?

By default work_mem is set to "1024". Increasing the value to "8192"
halves the execution time, still leaving a factor twenty-five
performance decrease compared to using the index. The machine I'm
testing this on is a very modest Pentium 3 at 450 MHz.

> Another theory is that you are using a locale in which strcoll() is
> horridly expensive :-(

Running 'locale' indicates I'm using "en_US.UTF-8" with language
"en_NL:en". My databases all use the UTF8 encoding.

Sincerely,

Frank

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Decibel! 2007-08-16 19:51:10 Re: Integrated perc 5/i
Previous Message Steinar H. Gunderson 2007-08-16 17:59:15 Re: Integrated perc 5/i