RE: Using date format

Elango Velayutham <[email protected]> Tue, 25 Feb 2003 08:14:08 +0400
Newsgroups gmane.comp.db.oracle.devel
Message-ID <LYRIS-1796914-887273-2003.02.25-14.25.54--gcdod-oracle#[email protected]>
use dbms_utility.get_time to show the time difference....this gives the time
in milliseconds.
something of this sort might help you....

begin
time1 = dbms_utility.get_time;
-- your process
time2 = dbms_utility.get_time;
timediff = (time2-time1)/100 seconds....
end;

HTH
Elango 




-----Original Message-----
From: Ngew [mailto:[email protected]]
Sent: 24 February 2003 16:41
To: Oracle
Subject: [oracle] Using date format


I am creating the report which required to show the response time, my 
calculation of response time like this :

(TIME1 - TIME2)*86400
which will show in second.  

However i realize that if the TIME1 value =
'18-01-2003 00:00:00' (which is mid-night) and TIME2 value = '18-01-2003 
23:55:47', it will show negative figure (-86147).  

Both columns are date format in mytable, is that any way to do it??

Appreciate if you can help me some hint!!

Rgds,
Ngew
---
Change your mail options at http://p2p.wrox.com/manager.asp or 
to unsubscribe send a blank email to %%email.unsub%%.


---
Change your mail options at http://p2p.wrox.com/manager.asp or 
to unsubscribe send a blank email to [email protected].