Cách flashback cả database về thời thời điểm bất kỳ:
SQL> select * from V$FLASHBACK_DATABASE_LOG;
SQL> Shutdown immediate;
SQL> Startup mount;
SQL> flashback database to timestamp TO_TIMESTAMP( '2022-03-04 19:00:00','YYYY-MM-DD HH24:MI:SS');
Flashback complete.
SQL> alter database open resetlogs;
FOR FLASHBACK TO SCN….
Alter database mount;
Flashback database to scn=12355;
To get current_scn: select current_scn from v$database;
TO FLASHBACK TO SEQUENCE NUMBER…
Alter database mount;
Flashback database to sequence=223 thread=1;