Case sensitivity

Lists: pgsql-general
From: "Dario Ottaviano" <dario_ottaviano(at)togliquestovirgilio(dot)it>
To: pgsql-general(at)postgresql(dot)org
Subject: Case sensitivity
Date: 2004-01-11 09:29:56
Message-ID: oI8Mb.242722$vO5.10009592@twister1.libero.it
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-general

I use postgres on a window server (IIS 5.1)
Is there anybody that knows if is possible to make postgres no case
sensitive in the manipulating data into tables/views?

Thank you.
D.Ottaviano


From: Richard Huxton <dev(at)archonet(dot)com>
To: "Dario Ottaviano" <dario_ottaviano(at)togliquestovirgilio(dot)it>, pgsql-general(at)postgresql(dot)org
Subject: Re: Case sensitivity
Date: 2004-01-12 09:57:32
Message-ID: 200401120957.32060.dev@archonet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-general

On Sunday 11 January 2004 09:29, Dario Ottaviano wrote:
> I use postgres on a window server (IIS 5.1)
> Is there anybody that knows if is possible to make postgres no case
> sensitive in the manipulating data into tables/views?

There's no general "case_sensitive = yes/no" flag. There are case-insensitive
operators you can use though.

--
Richard Huxton
Archonet Ltd


From: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
To: Richard Huxton <dev(at)archonet(dot)com>
Cc: Dario Ottaviano <dario_ottaviano(at)togliquestovirgilio(dot)it>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: Case sensitivity
Date: 2004-01-12 17:58:22
Message-ID: Pine.LNX.4.33.0401121057560.19667-100000@css120.ihs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-general

On Mon, 12 Jan 2004, Richard Huxton wrote:

> On Sunday 11 January 2004 09:29, Dario Ottaviano wrote:
> > I use postgres on a window server (IIS 5.1)
> > Is there anybody that knows if is possible to make postgres no case
> > sensitive in the manipulating data into tables/views?
>
> There's no general "case_sensitive = yes/no" flag. There are case-insensitive
> operators you can use though.

Is there a case insensitive locale? Or is that even possible?


From: Richard Huxton <dev(at)archonet(dot)com>
To: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
Cc: Dario Ottaviano <dario_ottaviano(at)togliquestovirgilio(dot)it>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: Case sensitivity
Date: 2004-01-12 22:22:11
Message-ID: 200401122222.11458.dev@archonet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-general

On Monday 12 January 2004 17:58, scott.marlowe wrote:
> On Mon, 12 Jan 2004, Richard Huxton wrote:
> > On Sunday 11 January 2004 09:29, Dario Ottaviano wrote:
> > > I use postgres on a window server (IIS 5.1)
> > > Is there anybody that knows if is possible to make postgres no case
> > > sensitive in the manipulating data into tables/views?
> >
> > There's no general "case_sensitive = yes/no" flag. There are
> > case-insensitive operators you can use though.
>
> Is there a case insensitive locale? Or is that even possible?

I've heard it proposed, but don't believe anyone liked the idea enough to do
it. With my limited understanding of encoding/locale issues, that'd mean
adding support at the OS level, I think.

The other option would be an IVARCHAR type with suitably defined operators,
but that's hardly very portable.
--
Richard Huxton
Archonet Ltd


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
Cc: Richard Huxton <dev(at)archonet(dot)com>, Dario Ottaviano <dario_ottaviano(at)togliquestovirgilio(dot)it>, pgsql-general(at)postgresql(dot)org
Subject: Re: Case sensitivity
Date: 2004-01-12 22:27:13
Message-ID: 5506.1073946433@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-general

"scott.marlowe" <scott(dot)marlowe(at)ihs(dot)com> writes:
> Is there a case insensitive locale? Or is that even possible?

It's certainly possible, but I don't know of any standard locales that
behave like that.

One could also imagine developing a new set of comparison operators that
do case-insensitive comparison, and then making a special index opclass
for that. The locale-insensitive operators Peter built to optimize LIKE
indexing in 7.4 would be a good model.

regards, tom lane