SI
SI
discoversearch

We've detected that you're using an ad content blocking browser plug-in or feature. Ads provide a critical source of revenue to the continued operation of Silicon Investor.  We ask that you disable ad blocking while on Silicon Investor in the best interests of our community.  If you are not using an ad blocker but are still receiving this message, make sure your browser's tracking protection is set to the 'standard' level.
Technology Stocks : Oracle Corporation (ORCL) -- Ignore unavailable to you. Want to Upgrade?


To: John Mansfield who wrote (4689)12/20/1997 7:22:00 AM
From: John Mansfield  Respond to of 19080
 
Y2K-ORACLE Default date format

Found on C.S.Y2K. Thanks to Harlan.

Any thoughts?

John

------------------------

I found this quite interesting. You will need to read the entire article to easily understand the full implications.

dbmsmag.com

[snip]
Oracle columns of the date data-type can store dates ranging from January 1, 4712 BC to December 31, 4712 AD. Oracle uses its own internal format for storing dates, but conceptually you can think of the server as storing each date in the format YYYY-MM-DDHH24:MI:SS. Because all dates occurring in a column of datatype date are stored with a four-digit century, Oracle regards the Oracle Server as Y2K compliant.

However, the situation gets less rosy when we take into consideration the default date format. Since Oracle uses its own internal representation for dates, it must convert from this format to a readable format on output and vice versa on input. Oracle provides a wide range of date formats that the programmer can explicitly request or specify by using the to_char() and to_date() functions, respectively. However, if you don't use these functions (for example, you just reference the date as a string as in "select * from emp where hiredate > `01-JAN-97'"), Oracle relies on the default date format to perform the conversion. There is a great deal of Oracle SQL code in use that relies on the default date format - approximately three quarters of the Oracle SQL code that I've seen or coded in the last 10 years does.

The default date format for Oracle releases in North America has always been DD-MON-YY. Here's the potential pitfall: The YY always refers to years in the current century
[snip]