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: subtract dates

RE: subtract dates

From: Looney, Jason <Jason.Looney_at_echostar.com>
Date: Wed, 12 May 2004 09:25:36 -0600
Message-ID: <B8C9CF34B3F7164282C8610C93BB94AF01A921F7@riv-exchb1.echostar.com>


SELECT (TO_DATE ('05/05/04 08:22:00', 'DD/MM/YY HH:MI:SS') - TO_DATE ('05/05/04 06:00:00', 'DD/MM/YY HH:MI:SS')) * 24   FROM DUAL This will return the number of hours between the two dates. You can round that result if you want just the hour portion.

Jason.

-----Original Message-----

From: Huascar Espinoza [mailto:hespinoza_at_superele.gov.bo] Sent: Wednesday, May 12, 2004 9:16 AM
To: oracle-l_at_freelists.org
Subject: subtract dates

Hi guys: =20
 =20
How can I subtract two dates ('DD/MM/YY HH:MI:SS') to obtain the result = in hours? MONTHS_BETWEEN don't obtain a precise value. =20  =20
Thank you,

Hu=E1scar



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

To unsubscribe send email to: oracle-l-request_at_freelists.org put 'unsubscribe' in the subject line.
--

Archives are at http://www.freelists.org/archives/oracle-l/
FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html

-----------------------------------------------------------------
----------------------------------------------------------------
Please see the official ORACLE-L FAQ: http://www.orafaq.com
----------------------------------------------------------------
To unsubscribe send email to: oracle-l-request_at_freelists.org
put 'unsubscribe' in the subject line.
--

Archives are at http://www.freelists.org/archives/oracle-l/ FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html
Received on Wed May 12 2004 - 10:29:34 CDT

Original text of this message

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