From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Dhaval Jaiswal <dhaval(dot)jaiswal(at)enterprisedb(dot)com> |
Cc: | pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: to_timestamp error handling. |
Date: | 2010-02-24 19:45:34 |
Message-ID: | 201002241945.o1OJjYI11898@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
FYI, this behavior now returns:
test=> select to_timestamp('20096010','YYYYMMDD');
to_timestamp
------------------------
2013-12-18 00:00:00-05
(1 row)
which doesn't have the :30 but is still odd. I don't see any value
checking in to_timestamp.
---------------------------------------------------------------------------
Dhaval Jaiswal wrote:
> Hi All,
>
>
>
> postgres=# select to_timestamp('20096010','YYYYMMDD');
>
> to_timestamp
>
> ---------------------------
>
> 2013-12-18 00:00:00+05:30
>
> (1 row)
>
>
>
> The month is 60 in my case and it is giving some random value, whereas I am
> expecting some error message like date is not valid.
>
>
>
> Is it an expected behaviour?
>
>
> --
> Thanks & Regards,
> Dhaval Jaiswal
> EnterpriseDB
> Contact: 732-331-1300 Ext- 2022
> +91-20-30589 516 / 494
> web: www.enterprisedb.com
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com
PG East: http://www.enterprisedb.com/community/nav-pg-east-2010.do
+ If your life is a hard drive, Christ can be your backup. +
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2010-02-24 20:00:50 | Re: to_timestamp error handling. |
Previous Message | Bruce Momjian | 2010-02-24 18:11:10 | Re: [BUGS] BUG #4887: inclusion operator (@>) on tsqeries behaves not conforming to documentation |