pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
datestyle on windows environment: how to set?
2+ messages / 2 participants
[nested] [flat]

* datestyle on windows environment: how to set?
@ 2006-05-31 17:53 filippo <filippo2991@virgilio.it>
  2006-06-04 02:10 ` Re: datestyle on windows environment: how to set? Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 2+ messages in thread

From: filippo @ 2006-05-31 17:53 UTC (permalink / raw)
  To: pgsql-sql

Hello,

I want to set the datestyle = 'ISO, European' for all my databases. I
put that configuration into postgresql.conf file, but I didn't succeed.
After rebooting all dates are like that:

YYYY-MM-DD

I'd like to have

DD-MM-YYYY for my timestamp field.

I have the latest version of pgsql and perl.

Hereafter is an extract of my postgresql.conf file.

Thanks and best regards,
Filippo

# - Locale and Formatting -

datestyle = 'ISO, European'
#timezone = unknown			# actually, defaults to TZ
					# environment setting
#australian_timezones = off
#extra_float_digits = 0			# min -15, max 2
#client_encoding = sql_ascii		# actually, defaults to database
					# encoding

# These settings are initialized by initdb -- they might be changed
lc_messages = 'C'			# locale for system error message
					# strings
lc_monetary = 'C'			# locale for monetary formatting
lc_numeric = 'C'			# locale for number formatting
lc_time = 'C'				# locale for time formatting




^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: datestyle on windows environment: how to set?
  2006-05-31 17:53 datestyle on windows environment: how to set? filippo <filippo2991@virgilio.it>
@ 2006-06-04 02:10 ` Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 2+ messages in thread

From: Tom Lane @ 2006-06-04 02:10 UTC (permalink / raw)
  To: filippo <filippo2991@virgilio.it>; +Cc: pgsql-sql

"filippo" <filippo2991@virgilio.it> writes:
> I'd like to have
> DD-MM-YYYY for my timestamp field.

The closest display format to that is 'SQL, DMY':

regression=# set datestyle = 'sql, dmy';
SET
regression=# select current_date;
    date    
------------
 03/06/2006
(1 row)

See the discussion of datestyle values in
http://www.postgresql.org/docs/8.1/static/datatype-datetime.html#DATATYPE-DATETIME-OUTPUT

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2006-06-04 02:10 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-05-31 17:53 datestyle on windows environment: how to set? filippo <filippo2991@virgilio.it>
2006-06-04 02:10 ` Tom Lane <tgl@sss.pgh.pa.us>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox