Re: dealing with invalid date - Mailing list pgsql-general

From Scott Marlowe
Subject Re: dealing with invalid date
Date
Msg-id 1097985911.21035.12.camel@localhost.localdomain
Whole thread Raw
In response to dealing with invalid date  (Mage <mage@mage.hu>)
List pgsql-general
On Sat, 2004-10-16 at 21:03, Mage wrote:
>           Hi,
>
> can pgsql acceppt invalid date values? Sometimes it would be nice to
> convert 2003-02-29 to 2003-03-01 or to 2003-02-28 automatically instead
> of throwing back an error message.

If you're using a language with a date / time lib that does that, just
massage it through there first.

PostgreSQL is known for following the SQL spec, and more importantly for
considering your data to be important.  Carelessly munging dates to fit
them into a date field is a bad thing when it comes to your data.


pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: pgsql function using C++?, or at least C interfacing with C++ lib?
Next
From: "Net Virtual Mailing Lists"
Date:
Subject: Re: Tsearch2 trigger firing...