Skip site navigation (1) Skip section navigation (2)

Re: Locale-dependent case conversion in {identifier}

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Nicolai Tufar <ntufar(at)apb(dot)com(dot)tr>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Locale-dependent case conversion in {identifier}
Date: 2002-11-30 16:02:19
Message-ID: 160.1038672139@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-advocacypgsql-generalpgsql-hackers
Nicolai Tufar <ntufar(at)apb(dot)com(dot)tr> writes:
> Historically programs that operate in Turkish locale have
> chosen to hardcode the capitalisation of "i" in system
> messages and identifier names like this:

> Lower: "I" -> "i" and "Y'" -> "i".
> Upper: "y'"  -> "I" and "i" -> "I".

If that's the behavior you want, why don't you set up a variant locale
definition that does it that way?  That would fix *all* your locale-
dependent programs, not just Postgres ...

> Would it be acceptable if I submit a path that applies this
> special logic in src/backend/parser/scan.l if the locale is "tr_TR"?

It really seems like an inappropriate wart to me :-(

> Because for many folks setting locale to Turkish would
> render their database unusable. For, god forbid, if your
> sql has a column name written in capitlas including "I".
> It is not working.

I am not seeing why this is any worse than the universal problems of
using upper-case letters without double-quoting 'em.  If you
consistently spell the name the same way, you will not have a problem;
if you don't, you might have a problem, but why is it worse than
anyone else's?

			regards, tom lane

In response to

pgsql-hackers by date

Next:From: Bruce MomjianDate: 2002-11-30 16:13:51
Subject: Re: 7.4 Wishlist
Previous:From: Hannu KrosingDate: 2002-11-30 15:57:52
Subject: Re: 7.4 Wishlist

pgsql-advocacy by date

Next:From: Bruce MomjianDate: 2002-11-30 16:13:51
Subject: Re: 7.4 Wishlist
Previous:From: Hannu KrosingDate: 2002-11-30 15:57:52
Subject: Re: 7.4 Wishlist

pgsql-general by date

Next:From: Tom LaneDate: 2002-11-30 16:05:01
Subject: Re: strange pg_stats behaviour?
Previous:From: Hannu KrosingDate: 2002-11-30 15:57:52
Subject: Re: 7.4 Wishlist

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group