Monday , September 25 2017
Home / Oracle DBA / FLASHBACK TRANSACTION QUERY

FLASHBACK TRANSACTION QUERY

FLASHBACK TRANSACTION QUERY
—————————————————-

  1. SELECT xid, operation, start_scn,commit_scn, logon_user, undo_sql
FROM   flashback_transaction_query
WHERE  xid = HEXTORAW(‘0600030021000000’);
  1. update “SCOTT”.”FLASHBACK_VERSION_QUERY_TEST” set “DESCRIPTION” = ‘ONE’ where ROWID = ‘AAAMP9AAEAAAA
AYAAA’;
FLASHBACK TABLE
—————————–
Flashback table requires following privileges
1) FLASHBACK ANY TABLE or FLASHBACK object
2) SELECT,INSERT,DELETE and ALTER privs on table
3) Row movement must be enabled
CREATE TABLE flashback_table_test (
  id  NUMBER(10)
);
ALTER TABLE flashback_table_test ENABLE ROW MOVEMENT;
SELECT current_scn FROM v$database;
CURRENT_SCN
———–
     715315
INSERT INTO flashback_table_test (id) VALUES (1);
COMMIT;
SELECT current_scn FROM v$database;
CURRENT_SCN
———–
     715340
FLASHBACK TABLE flashback_table_test TO SCN 715315;
SELECT COUNT(*) FROM flashback_table_test;
  COUNT(*)
———-
         0
FLASHBACK TABLE flashback_table_test TO SCN 715340;
SELECT COUNT(*) FROM flashback_table_test;
  COUNT(*)
———-
         1
View More:
AUTOMATIC WORKLOAD REPOSITORY (AWR) REPORT
ORACLE INSTANCE TUNING WITH REPORTS
ORACLE DATABASE TUNING WITH EXAMPLES

Comments

comments

Check Also

How to switch on primary database to physical standby database

After configuration data guard then data is switching  into primary database  to standby database : …

Leave a Reply

Your email address will not be published. Required fields are marked *