Remigiusz Sokolowski ha scritto:
> Hi!
> I did something like that:
> torell=> set DataStyle to 'ISO';
>
> and get something like this:
> NOTICE: Unrecognized variable datastyle
> SET VARIABLE
>
> I try also with 'European' DataStyle - I remeber, that sometime ago this
> command functions OK, and we've made no changes in configuration of
> database.
>
hygea=> set DateStyle to 'ISO';
SET VARIABLE
>
> So my question is:
> If there is a way to set DataStyle manually?
> And if it is possible to set it default 'European' to all users?
> As I saw it seems, that every user has its own settings of this.
> TIA
> Rem
>
You can do this job in three different ways:
1. Setting PGDATESTYLE environment variable for everey client
as: export PGDATESTYLE='sql,european' # this format is:
dd/mm/yyyy
2. Running postmaster using -oe parameter to set format date to 'European'
convention.
3. Changing the following variables: bool EuroDates = true / false
int DateStyle = USE_ISO_DATES
USE_POSTGRES_DATES USE_ISO_DATES
USE_SQL_DATES USE_GERMAN_DATES on
~/src/backend/utils/init/globals.cfile before PostgreSQL
installation).
______________________________________________________________
PostgreSQL 6.5.0 on i586-pc-linux-gnu, compiled by gcc 2.7.2.3
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Jose'