Saturday, September 6, 2008

dbms_application_info

dbms_application_info.set_module (module_name=>'test_package', action_name=>'starting batch');
dbms_application_info.set_action
(action_name => 'loading table x');
dbms_application_info.set_client_info ('inserting row ' || rowcount);

select module, action, client_info from v$session;

Also use
dbms_application_info.set_session_longops to set v$session_longops.
Can set sofar, total work and Oracle calculates time remaining.