Re: How to create database with default system locale is set to et_EE.UTF-8 - Mailing list pgsql-general

From Andrus
Subject Re: How to create database with default system locale is set to et_EE.UTF-8
Date
Msg-id D9AA39E54DBA4DCC84C894F5F3EEE411@dell2
Whole thread Raw
In response to Re: How to create database with default system locale is set to et_EE.UTF-8  (Adrian Klaver <adrian.klaver@gmail.com>)
Responses Re: How to create database with default system locale is set to et_EE.UTF-8
List pgsql-general
> What application?

My application.

>Well you would use template0 as the TEMPLATE only if you wanted to CREATE a
database with different collation than that in template1(the default
template for
>the CREATE DATABASE command). So the question then is, why is the database
>cluster being created with a collation of en_US.UTF-8 when the locale is
>supposed to have been set to et_EE.UTF-8?
>First are you sure that dpkg-reconfigure locales  is actually resetting the
locale?

dpkg-reconfigure locales
Generating locales (this might take a while)...
  en_US.UTF-8... done
  et_EE.UTF-8... done
Generation complete.
*** update-locale: Warning: LANGUAGE ("en_US:en") is not compatible with
LANG (et_EE.UTF-8). Disabling it.

> Second when you connect to the cluster with psql what does \l show for
> encoding
> and collation?

psql postgres
psql (9.1.1)
Type "help" for help.

postgres=> \l
                                   List of databases
   Name    |   Owner    | Encoding |   Collate   |    Ctype    |   Access
privileges
-----------+------------+----------+-------------+-------------+-----------------------

postgres  | postgres   | UTF8     | en_US.UTF-8 | en_US.UTF-8 |
template0 | postgres   | UTF8     | en_US.UTF-8 | en_US.UTF-8 | =c/postgres
+
           |            |          |             |             |
postgres=CTc/postgres
template1 | postgres   | UTF8     | en_US.UTF-8 | en_US.UTF-8 | =c/postgres
+
           |            |          |             |             |
postgres=CTc/postgres

Andrus.


pgsql-general by date:

Previous
From: Юра Величко
Date:
Subject: Default value of column in information_schema
Next
From: Hanns Hartman
Date:
Subject: Re: Trying to understand postgres crash