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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Date format RR limitations. (adding; Please answer, Thomas Kyte!)

Re: Date format RR limitations. (adding; Please answer, Thomas Kyte!)

From: Eric Hanson <ehanson_at_gr.com>
Date: Fri, 05 Mar 1999 10:19:25 -0700
Message-ID: <36E0121D.5B8C0F54@gr.com>


Oracle magazine a couple of months back had a great article on Y2K and how the different nls_date_format settings would interact. If you alter the setting to DD-MON-YYYY and enter a 2-digit year, the year returned would be lead by two zeros. ie;

alter session set nls_date_format = 'DD-MON-YYYY';

create table t1
  (c1 date);

commit;

insert into t1
  c1 values ('12-DEC-99');

commit;

select * from t1;

C1



12-DEC-0099 Eric Hanson, DBA

dhmac wrote:

> Arjan van Bentem wrote in message <36dcd363$0$13308_at_pascal>...
> [...]
> >
> >See above. It does *not* matter. Oracle always stores the dates fully Y2k
> >compliant (and has done since a long time), regardless whether it is in the
> >14th or 22nd century. It just is inputting two-digits years that gives you the
> >problem. Using RR, or even better RRRR for the input mask just helps you to
> >get the dates into the database. However, it is really a nice add-on to help
> >make your apps Y2k compliant. New apps should definitly use YYYY.
> >
> I know how RRRR works, but how does YYYY handle 2-digit years?
Received on Fri Mar 05 1999 - 11:19:25 CST

Original text of this message

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