Re: specific query (not all) on Pg8 MUCH slower than Pg7

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Susan Russo <russo(at)morgan(dot)harvard(dot)edu>
Cc: pgsql-performance(at)postgresql(dot)org, harvsys(at)morgan(dot)harvard(dot)edu
Subject: Re: specific query (not all) on Pg8 MUCH slower than Pg7
Date: 2007-05-08 14:48:25
Message-ID: 1160.1178635705@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Susan Russo <russo(at)morgan(dot)harvard(dot)edu> writes:
> Despite numerous efforts, we're unable to solve a severe performance limitation between Pg 7.3.2
> and Pg 8.1.4.

> The query and 'explain analyze' plan below, runs in
> 26.20 msec on Pg 7.3.2, and
> 2463.968 ms on Pg 8.1.4,

You're not getting the indexscan optimization of the LIKE clause, which
is most likely due to having initdb'd the 8.1 installation in something
other than C locale. You can either redo the initdb in C locale (which
might be a good move to fix other inconsistencies from the 7.3 behavior
you're used to) or create a varchar_pattern_ops index on the column(s)
you're using LIKE with.

regards, tom lane

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Steinar H. Gunderson 2007-05-08 14:48:34 Re: specific query (not all) on Pg8 MUCH slower than Pg7
Previous Message Susan Russo 2007-05-08 14:18:34 specific query (not all) on Pg8 MUCH slower than Pg7