Re: Date not being parsed as expected

From: rolf(dot)ostvik(at)axxessit(dot)no
To: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Date not being parsed as expected
Date: 2002-09-06 08:44:56
Message-ID: OF1AF639DD.8523689C-ONC1256C2C.002F2CA5@axxessit.no
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 2002-09-06 10:19, Martijn van Oosterhout <kleptog(at)svana(dot)org> wrote:
>On Fri, Sep 06, 2002 at 04:24:23PM +0900, Jean-Christian Imbeault wrote:
>> The following insert:
>> insert into t values('01-10-29')
>> gives the following result in the DB:
>> select * from t
>> d
>> ------------
>> 2029-01-10
>>
>
>Wow. Talk about an ambiguous date! That could be:
>
>1 October 2029 01/10/2029
>January 10 2029 10/01/2029
>2001-10-29 29/10/2001
>
>I don't think ISO dates are allowed to abbreviate any portion, especially
>the year, since that is what makes the date style clear and unambiguous.

I do not have the specification to look at but from some links which
discuss it i get the understanding that:
'01-10-29' (or '011029') should be intepreted as 29 october 1029. (according to ISO8601.)

Some links:
http://www.merlyn.demon.co.uk/datefmts.htm#8601

Browse pgsql-general by date

  From Date Subject
Next Message Thomas O'Dowd 2002-09-06 09:29:22 Re: 7.3b1 installation
Previous Message Jean-Christian Imbeault 2002-09-06 08:33:58 Re: Date not being parsed as expected