The below can be used to time the execution time for a given sql or a procedure or function.

Thought tkprof is the only authentic tool to calculate time taken for   sql execution, the below can be useful to get a quick idea about the same.

 

set echo on

variable lv_sec number

 

exec :lv_sec := dbms_utility.get_time

 

set termout off

 

select count(*) from  all_objects

/

 

set termout on

 

exec dbms_output.put_line( ((dbms_utility.get_time-:lv_sec)/100) || ' seconds...' )

Hosted by www.Geocities.ws

1