From: Peter Eisentraut <peter_e@gmx.net>
To: Chris Cox <cjcox@optushome.com.au>
Cc: pgsql-sql@postgresql.org
Subject: Re: LIKE on index not working
Date: Thu, 22 Jul 2004 14:41:04 +0200
Message-ID: <200407221441.05497.peter_e@gmx.net> (raw)
In-Reply-To: <030e01c46fbe$e8baeb90$5100000a@PHOENIX>
References: <030e01c46fbe$e8baeb90$5100000a@PHOENIX>
Am Donnerstag, 22. Juli 2004 09:38 schrieb Chris Cox:
> For some reason I just can't get this to use the index for the following
> query. I'm using PostgreSQL 7.3.4.
In 7.3, LIKE cannot use an index unless you set the locale to C. In 7.4, LIKE
can use an index, but it has to be a different kind of index, as explained
here:
http://www.postgresql.org/docs/7.4/static/indexes-opclass.html
--
Peter Eisentraut
http://developer.postgresql.org/~petere/
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: peter_e@gmx.net, cjcox@optushome.com.au
Subject: Re: LIKE on index not working
In-Reply-To: <200407221441.05497.peter_e@gmx.net>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox