Обсуждение: Installation Questions (FreeBSD / Windows / Postgres 9)

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

Installation Questions (FreeBSD / Windows / Postgres 9)

От
Panos Katergiathis
Дата:
Hello all

My goal is to install and run Postgresql 9 under FreeBSD and Windows
with selected database cluster encoding / collation / locale to be
UTF-8.

Unfortunately, it has been a while since i last compiled and installed
Postgresql on Linux machines. I remember that selecting the proper
locale and encoding for the database cluster was a matter to be
decided at built time. Is it still so for version 9?

If yes, how does one go about installing the FreeBSD port, while
actually choosing the locale and encoding for the cluster?
Also, how does one do it under Windows? (i assume that there must be
modern ways to do it, because back then i had to install Cygwin and
take it from there, without really having the ability to select UTF-8,
since it was not an option).

Thank you in advance for any replies. I could not locate such
information within the FreeBSD community, let alone the Windows
community.

Regards

Panos

Re: Installation Questions (FreeBSD / Windows / Postgres 9)

От
Dimitri Fontaine
Дата:
Panos Katergiathis <eyeprotocol@gmail.com> writes:
> Unfortunately, it has been a while since i last compiled and installed
> Postgresql on Linux machines. I remember that selecting the proper
> locale and encoding for the database cluster was a matter to be
> decided at built time. Is it still so for version 9?

No, see CREATE DATABASE documentation here:

  http://www.postgresql.org/docs/9/static/sql-createdatabase.html

CREATE DATABASE name
    [ [ WITH ] [ OWNER [=] user_name ]
           [ TEMPLATE [=] template ]
           [ ENCODING [=] encoding ]
           [ LC_COLLATE [=] lc_collate ]
           [ LC_CTYPE [=] lc_ctype ]
           [ TABLESPACE [=] tablespace ]
           [ CONNECTION LIMIT [=] connlimit ] ]

Regards,
--
Dimitri Fontaine
http://2ndQuadrant.fr     PostgreSQL : Expertise, Formation et Support