From: | Oliver Elphick <olly(at)lfix(dot)co(dot)uk> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | PostgreSQL Patches <pgsql-patches(at)postgresql(dot)org> |
Subject: | Re: psql patch for datestyle |
Date: | 2003-03-03 16:26:49 |
Message-ID: | 1046708809.2173.137.camel@linda.lfix.co.uk |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-patches |
On Mon, 2003-03-03 at 14:32, Tom Lane wrote:
> Oliver Elphick <olly(at)lfix(dot)co(dot)uk> writes:
> > This patch sets DATESTYLE to ISO at the start of a pg_dump, so that the
> > dates written into the dump will be restorable onto any database,
> > regardless of how its default datestyle is set.
>
> I have forgotten: will an ISO-style date be read in correctly regardless
> of the datestyle setting at load time? Or do we need to make pg_dump
> issue SET DATESTYLE in the dump script as well?
I tested it by changing the datestyle in postgresql.conf to postgres,us
and it read in OK there. On input, any recognisable date format can be
used, but where there is ambiguity between US and European style, there
can be problems. With ISO format there can be no ambiguity.
--
Oliver Elphick Oliver(dot)Elphick(at)lfix(dot)co(dot)uk
Isle of Wight, UK http://www.lfix.co.uk/oliver
GPG: 1024D/3E1D0C1C: CA12 09E0 E8D5 8870 5839 932A 614D 4C34 3E1D 0C1C
========================================
"A new commandment I give to you, that you love one
another, even as I have loved you."
John 13:34
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2003-03-03 17:55:12 | Re: [PATCHES] XML ouput for psql |
Previous Message | Marc G. Fournier | 2003-03-03 14:52:14 | Re: Off topic - was Re: [PATCHES] ALTER SEQUENCE |