Re: Default Locale in initdb

From: pgsql(at)mohawksoft(dot)com
To: "Bruce Momjian" <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: "Christopher Kings-Lynne" <chriskl(at)familyhealth(dot)com(dot)au>, "Paul Ramsey" <pramsey(at)refractions(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Default Locale in initdb
Date: 2004-06-03 01:53:46
Message-ID: 16661.24.91.171.78.1086227626.squirrel@mail.mohawksoft.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> Christopher Kings-Lynne wrote:
>> > When this new behavior was introduced, and I migrated our databases to
>> > the new PgSQL version (dump/restore), the locale of all my databases
>> > were silently changed from C to US_en. This broke one application in a
>> > very subtle way because of slightly different sort behavior in the
>> > different locale. Tracking it down was quite tricky.
>> >
>> > PgSQL was just a little too helpful in this case.
>>
>> Seems pretty nasty thing to do. I would so vote for making -E and -W
>> and --locate required flags to initdb. Oh the amount of time I've spent
>> with people in IRC..
>
> What about folks who don't use locales?

This has bitten me a couple times. In what version did it change?

My feeling, and I'd like to see what everyone else thinks, is that if you
do not specify a locale, you get "C."

That way things work as you'd expect in most cases.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2004-06-03 02:08:07 pgsql-server: Adjust our timezone library to use pg_time_t (typedef'd as
Previous Message Christopher Kings-Lynne 2004-06-03 01:51:43 Re: Default Locale in initdb