Re: How to boost performance of ilike queries ?

From: Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>
To: Antony Paul <antonypaul24(at)gmail(dot)com>
Cc: Russell Smith <mr-russ(at)pws(dot)com(dot)au>, pgsql-performance(at)postgresql(dot)org
Subject: Re: How to boost performance of ilike queries ?
Date: 2005-01-25 14:01:25
Message-ID: 20050125055555.J11415@megazone.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Tue, 25 Jan 2005, Antony Paul wrote:

> Creating an index and using lower(column) does not change the explain
> plan estimates.
> It seems that it is not using index for like or ilike queries
> irrespective of whether it have a pattern matching character in it or
> not. (using PostgreSQL 7.3.3)

I believe in 7.3.x an index is only considered for like in "C" locale, I
think the *_pattern_op opclasses were added in 7.4 for which you can make
indexes that are considered for non wildcard starting search strings in
non "C" locales. And it may have trouble doing estimates before 8.0 on the
functional index because of lack of statistics. You may want to consider
an upgrade once 8.0 shakes out a bit.

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Tatsuo Ishii 2005-01-25 14:19:17 Re: PostgreSQL clustering VS MySQL clustering
Previous Message Antony Paul 2005-01-25 13:01:45 PostgreSQL not utilising available memory