Re: ILIKE vs indices

From: Greg Stark <stark(at)mit(dot)edu>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: James Cloos <cloos(at)jhcloos(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: ILIKE vs indices
Date: 2012-12-29 14:13:26
Message-ID: CAM-w4HPPJFPFQLS5V2nK+76_REo-53mHbo9OEwuE0oM=Eyj6aQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Dec 29, 2012 at 2:05 PM, Greg Stark <stark(at)mit(dot)edu> wrote:
> I can't quite wrap my head around the idea of "LIKE" and collations
> having any meaningful interaction anyways. I certainly can't come up
> with anything better than "lower() like lower()" (or "upper() like
> upper()").

Hm. Maybe I spoke too fast. Perhaps we should just call strcasecmp()
character by character, or even call strcasecmp() on any substring of
the pattern that doesn't contain _ or % ? The latter would be pretty
hopeless to ever use a btree index though.

--
greg

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Stephen Frost 2012-12-29 14:34:41 Re: Proposal: Store "timestamptz" of database creation on "pg_database"
Previous Message Dimitri Fontaine 2012-12-29 14:12:07 Re: Proposal: Store "timestamptz" of database creation on "pg_database"