Friday, August 15, 2008

Log Miner

alter database add supplemental log data;

select suppemental_log_data_min from v$database;

SQL> EXECUTE DBMS_LOGMNR.ADD_LOGFILE(LOGFILENAME => '/oracle/TST/oraarch/TST_1_48_6b8c0516_663174038.arc', OPTIONS => DBMS_LOGMNR.NEW);
SQL> EXECUTE DBMS_LOGMNR.START_LOGMNR(OPTIONS => DBMS_LOGMNR.DICT_FROM_ONLINE_CATALOG);
SQL> select SCN, OPERATION, SQL_REDO, SQL_UNDO from V$LOGMNR_CONTENTS;

begin
dbms_logmnr.start_logmnr(
startTime => '2007-04-16 00:00:00',
endTime => '2007-04-20 00:00:00',
options => dbms_logmnr.DICT_FROM_ONLINE_CATALOG + dbms_logmnr.CONTINUOUS_MINE);
end;