Skip to content

Instantly share code, notes, and snippets.

@Tracnac
Created September 23, 2022 16:23
Show Gist options
  • Select an option

  • Save Tracnac/3470ce667cf063dd728d3efb1f9b7159 to your computer and use it in GitHub Desktop.

Select an option

Save Tracnac/3470ce667cf063dd728d3efb1f9b7159 to your computer and use it in GitHub Desktop.
Flashback database #oracle #sql
-- Sqlplus

alter system set db_flashback_retention_target=1440 scope=both sid='*';
alter system set db_recovery_file_dest_size=64G scope=both sid='*';
alter system archive log current;

ALTER DATABASE FLASHBACK ON;
CREATE RESTORE POINT 120714_1139 GUARANTEE FLASHBACK DATABASE;

-- Rman :

LIST RESTORE POINT ALL;
shutdown immediate;
startup mount;
FLASHBACK DATABASE TO RESTORE POINT 'CHANGE_ID';
alter database open resetlogs;

-- Sqlplus :

ALTER DATABASE FLASHBACK OFF;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment