checking date format with postgresql without creating a table - Mailing list pgsql-general

From Neil Zanella
Subject checking date format with postgresql without creating a table
Date
Msg-id Pine.A41.4.33.0111190325360.26044-100000@gpu1.srv.ualberta.ca
Whole thread Raw
Responses Re: checking date format with postgresql without creating
List pgsql-general
Hello,

I would like to be able to check whether some date is a valid date by
asking postgresql? Is this possible? The idea is that when an invalid
date is entered into a postgresql table an error is output. Thus to
check the validity of a date from JDBC in a rather lazy way one could
create a table called checkdate with a single column of type date and
insert into that column. If the database generates an error than an
SQLException is output and the user knows that the date is incorrect
and thus needs to prompt for a date again. Now I want to do the
above without having to create any tables. Is this possible?

Thanks,

Neil


pgsql-general by date:

Previous
From: cs1spw@bath.ac.uk (Simon Willison)
Date:
Subject: A newbie's opinion - postgres NEEDS a Windows binary!
Next
From: sir_anodos@yahoo.com (anodos)
Date:
Subject: Good configuration?