12 March 2010

Tkprof

TKPROF: Yes, it is still used but the FOREGROUND_DUMP_DEST is no longer
used. There is info in the Oracle docs on this. Here is the syntax:

04 March 2010

Восстановить удаленную процедуру в Oracle и т.п.
select text
from dba_source as of timestamp (systimestamp - interval '3' hour) -- interval '5' minute)
where owner =
   and name =
   and type = 'PACKAGE' --'FUNCTION', 'PROCEDURE'
order by name
        , type
        , line;

01 March 2010

Example of how to trace a session and use tkprof

Enable trace for a user session:
SQLPLUS> exec sys.dbms_system.set_sql_trace_in_session(SID, SERIAL, true);
Use tkprof to analyze the trace file:
tkprof [TRACE FILE] [OUTPUT FILE] explain=/ sort=prsela,exeela,fchela
table=ops\$oracle.plan_table