Обсуждение: BUG #4328: help in creating database encoded with LATIN1

Поиск
Список
Период
Сортировка

BUG #4328: help in creating database encoded with LATIN1

От
"andrew victoria"
Дата:
The following bug has been logged online:

Bug reference:      4328
Logged by:          andrew victoria
Email address:      rtz_andy@yahoo.com
PostgreSQL version: 8.3.1
Operating system:   fedora core 9
Description:        help in creating database encoded with LATIN1
Details:

i got an error message
createdb: database creation failed: ERROR:  encoding LATIN1 does not match
server's locale en_US.utf8
DETAIL:  The server's LC_CTYPE setting requires encoding UTF8.

when im trying to create a database encoded with LATIN1 which is needed in
our work. what will i do?

many thanks en more power..

Re: BUG #4328: help in creating database encoded with LATIN1

От
Alvaro Herrera
Дата:
andrew victoria wrote:

> i got an error message
> createdb: database creation failed: ERROR:  encoding LATIN1 does not match
> server's locale en_US.utf8
> DETAIL:  The server's LC_CTYPE setting requires encoding UTF8.
>
> when im trying to create a database encoded with LATIN1 which is needed in
> our work. what will i do?

You need to run initdb again, specifying --locale=en_US.  You can't
create a database whose encoding does not match the locale used by
initdb.

--
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

Re: BUG #4328: help in creating database encoded with LATIN1

От
valgog
Дата:
On Jul 28, 8:27=A0am, rtz_a...@yahoo.com ("andrew victoria") wrote:
> The following bug has been logged online:
>
> Bug reference: =A0 =A0 =A04328
> Logged by: =A0 =A0 =A0 =A0 =A0andrew victoria
> Email address: =A0 =A0 =A0rtz_a...@yahoo.com
> PostgreSQL version: 8.3.1
> Operating system: =A0 fedora core 9
> Description: =A0 =A0 =A0 =A0help in creating database encoded with LATIN1
> Details:
>
> i got an error message
> createdb: database creation failed: ERROR: =A0encoding LATIN1 does not ma=
tch
> server's locale en_US.utf8
> DETAIL: =A0The server's LC_CTYPE setting requires encoding UTF8.
>
> when im trying to create a database encoded with LATIN1 which is needed in
> our work. what will i do?
>
> many thanks en more power..
>
> --
> Sent via pgsql-bugs mailing list (pgsql-b...@postgresql.org)
> To make changes to your subscription:http://www.postgresql.org/mailpref/p=
gsql-bugs

Using LATIN1 encoding will introduce a lot of problems for you, in
case you will need to use characters that are out of LATIN1 scope
later. Think twice before counting 'pros' of having LATIN1 encoding (I
do not see the 'pros' in case you are using US ASCII symbols mainly,
as UTF8 will keep them 1 byte long (ASCII actually), and if you
occasionally will have to use some other non-LATIN1 symbols (and there
are many), you will not be able to change the encoding on the running
system without several hours of system downtime and you having a
headache doing initdbs, backups and restores).

-- Valentine Gogichashvili