Thanks all, Thomas's function with a little tweaking has done the job very nicely. -----Original Message----- From: Tim Fleury [mailto:Tim_Fleury@xxxxxxxxxxxx] Sent: Friday, May 19, 2006 5:42 PM To: gorbyx@xxxxxxxxx; rjamya@xxxxxxxxx Cc: Thomas.Mercadante@xxxxxxxxxxxxxxxxx; Goulet, Dick; _oracle_L_list Subject: RE: Elapsed Time I use this to show the length of a lock being held. It's good for locks less than 24 hours. select name, l.owner "owner", osuser, session_id, machine, process, CEIL(MOD(FLOOR(last_convert/3600),24)) "LockHH", CEIL(MOD(FLOOR(last_convert/60),60)) "LockMM", CEIL(MOD(last_convert,60)) "LockSS" from dba_dml_locks l, v$session s where l.session_id = s.sid and name not like '%PLAN_TABLE%' and l.session_id <> 99999 order by name -----Original Message----- From: oracle-l-bounce@xxxxxxxxxxxxx [mailto:oracle-l-bounce@xxxxxxxxxxxxx] On Behalf Of Alex Gorbachev Sent: Friday, May 19, 2006 2:30 PM To: rjamya@xxxxxxxxx Cc: Thomas.Mercadante@xxxxxxxxxxxxxxxxx; DGoulet@xxxxxxxx; _oracle_L_list Subject: Re: Elapsed Time Well, not realy coz instead of sysdate there is number of seconds. 2006/5/19, rjamya <rjamya@xxxxxxxxx>: > select to_char(sysdate,'hh24') || ' hours ' || to_char(sysdate,'mi') > || ' minutes ' || to_char(sysdate,'ss') || ' seconds ' from dual > / > > something like this won't work??? > Raj > -- > //www.freelists.org/webpage/oracle-l > > > -- Best regards, Alex Gorbachev http://oracloid.blogspot.com -- //www.freelists.org/webpage/oracle-l -- //www.freelists.org/webpage/oracle-l