From: | Joel Burton <jburton(at)scw(dot)org> |
---|---|
To: | Thorsten Mauch <mauch(at)imkenberg(dot)de> |
Cc: | "'pgsql-novice(at)postgresql(dot)org'" <pgsql-novice(at)postgresql(dot)org> |
Subject: | Re: case insensitive database ? |
Date: | 2001-04-24 22:25:31 |
Message-ID: | Pine.LNX.4.21.0104241822290.22793-100000@olympus.scw.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-novice |
On Wed, 25 Apr 2001, Thorsten Mauch wrote:
> Is it possible to setup a database that is case insensitive ?
> is it also possible with a multbyte database ?
AFAIK, no, it's not possible to set up a case-insensitive database.
We're very into sensitivity in this community. :-)
Some possibilities:
the ILIKE operator does case insensitive searching,
as does the case insensitive regex operator (~*).
search using lower() or upper().
select * from pers where lower(fname) = 'joel';
(to speed these up, you can index pers on lower(fname)!)
"\h create index" for help
have two fields, fname and fname_lower, with a trigger to copy
lower(fname) to fname_lower on update.
Good luck!
HTH,
--
Joel Burton <jburton(at)scw(dot)org>
Director of Information Systems, Support Center of Washington
From | Date | Subject | |
---|---|---|---|
Next Message | Poul L. Christiansen | 2001-04-24 22:26:09 | Re: case insensitive database ? |
Previous Message | Joel Burton | 2001-04-24 22:22:10 | Re: Re: BETWEEN clause |