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 -> Re: Input date of 01-JAN-99 Defaults to 01-JAN-2099

Re: Input date of 01-JAN-99 Defaults to 01-JAN-2099

From: John Alexander <jalexander_at_summitsoftwaredesign.com>
Date: Sat, 27 Jan 2001 03:59:12 GMT
Message-ID: <kIrc6.19296$Tl3.4359614@typhoon.tampabay.rr.com>

Any dates with 2 digit years it assumes are this century. You will need to use a format (like TO_DATE('01-JAN-99','DD-MON-RR') or TO_DATE('01-JAN-1999','DD-MON-YYYY')
Issac Rosa <issac.rosa_at_att.net> wrote in message news:jpqc6.39442$8V6.4105115_at_typhoon.tampabay.rr.com...
> I am trying to run this insert statement with a start_date of Jan 1, 1999:
> Insert into monthlyoffers
> (offer_title, offer_desc, start_date, end_date, username,
 pointofcontact,
> id_mom_category, id_market,
> inserted_date)
> Values
> ('Test','This is a test', '01-JAN-99', '', 'irosa', '', 8, 1,
> '26-JAN-01');
>
> The statement runs fine, but when I run this query:
> select to_char(start_date, 'DD-MON-YYYY')
> from monthlyoffers
> where start_date >='01-JAN-01';
>
> Result is: 01-JAN-2099
>
> Should this be happening? How do I force year 19xx?
>
>
>
>
Received on Fri Jan 26 2001 - 21:59:12 CST

Original text of this message

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