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: Y2K bug?

Re: Y2K bug?

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: 2000/07/10
Message-ID: <963262364.28990.0.pluto.d4ee154e@news.demon.nl>#1/1

I'm not sure whether this is a true Y2k bug, but it is a funny one. I already put a warning on the website for my colleague DBA's. Here's the scoop:
The installation script for SCOTT doesn't have centuries in the hiredates. So if you don't run with NLS_DATE_FORMAT=DD-MON-RR, you'll automatically get hiredates in the future, as missing parts are derived from the sysdate. So your first hire appeared in 2081, and so on, and that's why you'r getting negative numbers.

At this point I would like to ask the opinion of Thomas Kyte whether or not this should be filed as a bug. For me it is at least something to be documented (I know you shouldn't use the DD-MON-YY format, but surprisingly that's still the default)

Hth,

Sybrand Bakker, Oracle DBA

"Eric Cheng" <ycheng4_at_students.wisc.edu> wrote in message news:8kda7p$mrk$1_at_news.doit.wisc.edu...
> Hi fellows,
>
> I have a question for you.
> Please try to run the following command and let me know what you get.
>
> 1. select ename, SYSDATE, hiredate, (SYSDATE-hiredate)/7 WEEKS
> 2. from emp
>
> All I got are negative numbers, however are we supposed to get
> positive numbers? Is this a Y2K bug?
> IMO, the current date minus hiredate should be positive numbers.
> I am using ORACLE8i on Redhat, I haven't tried this on NT yet.
> Maybe you already ran into this one.
> Thanks!
>
> Eric Cheng
>
>
Received on Mon Jul 10 2000 - 00:00:00 CDT

Original text of this message

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