Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Force four-digit year?

Force four-digit year?

From: Yosi Greenfield <yosi_at_newsalert.com>
Date: Wed, 25 Aug 1999 16:41:59 -0400
Message-ID: <37C45517.3FA85CE4@newsalert.com>


Anyone know of a way to force the user to enter four-digit year for implicit conversions? Setting NLS_DATE_FORMAT will cause the database to allow four digits, and depending if you use RRRR oe YYYY will set it to something or other.

But you can still enter a two-digit year using implicit conversions (without to_date). Oracle will then set the century to 00 (for YY) or 19 or 20 (for RR).

Support said you can't force a four digit year. They kindly suggested I write triggers on all my date fields. Thank you Support.

Any better ideas? For lack of anything else, I'll end up with RRRR and some stern memos to our developers. But I'd rather force the developers to do something they'd rather not do - you know, code properly.

Thanks,

Yosi Received on Wed Aug 25 1999 - 15:41:59 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US