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

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Boolean dates...

RE: Boolean dates...

From: <Jared.Still_at_radisys.com>
Date: Wed, 22 Oct 2003 11:59:26 -0800
Message-ID: <F001.005D3FD7.20031022115926@fatcity.com>


This may clear it up:

select

   to_char(sysdate,'j')

   , to_char(to_date('06/05/2718','mm/dd/yyyy'),'j')
   , to_char(to_date(2713944,'j'),'mm/dd/yyyy bc')
   , to_char(to_date(728464,'j'),'mm/dd/yyyy bc')
from dual;

Jared

"Goulet, Dick" <DGoulet_at_vicr.com>
Sent by: ml-errors_at_fatcity.com
 10/22/2003 12:24 PM
 Please respond to ORACLE-L  

        To:     Multiple recipients of list ORACLE-L <ORACLE-L_at_fatcity.com>
        cc: 
        Subject:        RE: Boolean dates...


Jared,  

    If that's true there has got to be something a little "strange" in the way that Oracle computes julian dates. Beacuse to_date(728,464,'J') returns 05-JUN-2718, where as to_char(sysdate,'J') returns 2,452,935. (comma's added for clarity)  

Dick Goulet
Senior Oracle DBA
Oracle Certified 8i DBA
-----Original Message-----
Sent: Wednesday, October 22, 2003 11:39 AM To: Multiple recipients of list ORACLE-L

I think what your boss really means is 'julian' date.

Does he also want his database in mauve?

Try this:

select to_date(bdate,'j') from paam;

That said, the dates in your example are about 700 years into the future.

Jared

Jose Luis Delgado <joseluis_delgado_at_yahoo.com> Sent by: ml-errors_at_fatcity.com
 10/22/2003 08:19 AM
 Please respond to ORACLE-L

        
        To:        Multiple recipients of list ORACLE-L 
<ORACLE-L_at_fatcity.com> 
        cc:         
        Subject:        Boolean dates...



Hi to all!

We have an old app that manages something that my boss calls: boolean dates.

He told me that exists an algorithm that manages dates as a boolean format.

We have several tables in this form:

Note: The following table: PAAM
has the field BDATE defined as NUMBER.

sql> select bdate from paam
sql> where rownum < 6

BDATE



728464
728434
728403
728495
728283

now, I need to convert that format to an 'understandable' format to get the old data and old dates.

I'm looking (google-ing) for that subject but, without luck.

any ideas? help?, pls...

Thanks in advance

Regards!
JL



Do you Yahoo!?
The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com
--

Please see the official ORACLE-L FAQ: http://www.orafaq.net
--

Author: Jose Luis Delgado
 INET: joseluis_delgado_at_yahoo.com
Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).

--

Please see the official ORACLE-L FAQ: http://www.orafaq.net
--

Author:
  INET: Jared.Still_at_radisys.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Wed Oct 22 2003 - 14:59:26 CDT

Original text of this message

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