Re: RPM init-script: Why the locale setting? - Mailing list pgsql-general

From Stephan Szabo
Subject Re: RPM init-script: Why the locale setting?
Date
Msg-id 20040404161010.V90684@megazone.bigpanda.com
Whole thread Raw
In response to RPM init-script: Why the locale setting?  (Troels Arvin <troels@arvin.dk>)
List pgsql-general
On Sun, 4 Apr 2004, Troels Arvin wrote:

> Hello,
>
> In the init-script contained in the RPMs downloadable from the PostgreSQL
> site (I checked the one for Fedora), an explicit locale is set before
> running initdb. - And the explicit locale is not "C".
>
> This means that a PostgreSQL installation will not use indexes for LIKE
> queries (I just ran into this). See
> http://www.postgresql.org/docs/faqs/FAQ.html#4.8

Technically you should be able to use an index in the appropriate
*_pattern_ops opclass, but yes, normal indexes aren't used.

> I suggest that the init-script be rewritten so that LANG and LC_ALL are
> unset before initdb is run (which happens the first time PostgreSQL is
> started after the RPM-based installation).

Wouldn't this get in the way of having the server "do the right thing"
when in a locale that doesn't collate by "C" rules?

pgsql-general by date:

Previous
From: Shachar Shemesh
Date:
Subject: Version 1.0.0.4 released
Next
From: Bruce Momjian
Date:
Subject: Re: thread_test.c problems