Re: specific query (not all) on Pg8 MUCH slower than Pg7 - Mailing list pgsql-performance

From Tom Lane
Subject Re: specific query (not all) on Pg8 MUCH slower than Pg7
Date
Msg-id 1160.1178635705@sss.pgh.pa.us
Whole thread Raw
In response to specific query (not all) on Pg8 MUCH slower than Pg7  (Susan Russo <russo@morgan.harvard.edu>)
Responses Re: specific query (not all) on Pg8 MUCH slower than Pg7
List pgsql-performance
Susan Russo <russo@morgan.harvard.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

pgsql-performance by date:

Previous
From: Susan Russo
Date:
Subject: specific query (not all) on Pg8 MUCH slower than Pg7
Next
From: "Steinar H. Gunderson"
Date:
Subject: Re: specific query (not all) on Pg8 MUCH slower than Pg7