Does Lower make indexes useless?

Lists: pgsql-jdbc
From: "Clemens Eisserer" <linuxhippy(at)gmail(dot)com>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: Does Lower make indexes useless?
Date: 2006-05-05 17:48:05
Message-ID: 194f62550605051048n6cadb63fl3272085ded3d95f1@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-jdbc

Hi,

I am using queries very often which look like "... WHERE
LOWER(field)='..';" to allow case-insensitive search on varchar
columns.

Does this make indexes useless or are there algorythmns which allow
using indexes even in this case?
Are there ways how this could be done in a better way?

Thank you in advance, lg Clemens


From: Kris Jurka <books(at)ejurka(dot)com>
To: Clemens Eisserer <linuxhippy(at)gmail(dot)com>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Does Lower make indexes useless?
Date: 2006-05-05 17:54:32
Message-ID: Pine.BSO.4.63.0605051249080.13150@leary2.csoft.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-jdbc

On Fri, 5 May 2006, Clemens Eisserer wrote:

> I am using queries very often which look like "... WHERE
> LOWER(field)='..';" to allow case-insensitive search on varchar
> columns.
>
> Does this make indexes useless or are there algorythmns which allow
> using indexes even in this case?
> Are there ways how this could be done in a better way?
>

This question has nothing to do with Java or JDBC, so this isn't the right
list. You should try -novice or -general.

http://www.postgresql.org/docs/8.1/static/indexes-expressional.html

Kris Jurka


From: "Clemens Eisserer" <linuxhippy(at)gmail(dot)com>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Does Lower make indexes useless?
Date: 2006-05-05 18:09:01
Message-ID: 194f62550605051109q18216016o17f657866d7be570@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-jdbc

Sorry for the traffic, I was already subscribed and I was too lazy.

> This question has nothing to do with Java or JDBC, so this isn't the right
> list. You should try -novice or -general.
>
> http://www.postgresql.org/docs/8.1/static/indexes-expressional.html
Perfect, thanks a lot :-)

Thanks again, lg Clemens