1, check whether to start the flash back delete
SQL> show Parameter recyclebin; NAME TYPE VALUE--------------------------------------------------------------------- --------recyclebin string on
Start the Flash back
2. Test Flash back deleted table:
Create two identical tables, and then delete them and restore them.
Sql> Create TableEdu.test_flash (ID Number( A), namevarchar2( -)); Tablecreated SQL> Insert intoEdu.test_flashValues(1,'1'); 1Row inserted SQL> Commit; CommitComplete SQL> Drop TableEdu.test_flash;Tabledropped SQL> Create TableEdu.test_flash (ID Number( A), namevarchar2( -)); Tablecreated SQL> Insert intoEdu.test_flashValues(2,'2'); 1Row inserted SQL> Commit; CommitComplete SQL> Drop TableEdu.test_flash;TableDropped
View Recycle Bin
Sql> SelectOwner,original_name,object_name, Ts_name,droptime fromDba_recyclebinwhereOwner='EDU'; OWNER original_nameobject_namets_name Droptime------------------------------ -------------------------------- ------------------------------ ---------------- -------------- -------------------EDU Test_flash bin$mfwmgr6pc/Lguweaah94la==$0USERS .-Geneva- -: -: A: GenevaEDU Test_flash BIN$MFWMGR6QC/Lguweaah94la==$0USERS .-Geneva- -: -: A: to
Recovering a deleted table
SQL>tabletodrop; Done
View Recycle Bin again
Sql> SelectOwner,original_name,object_name, Ts_name,droptime fromDba_recyclebinwhereOwner='EDU'; OWNER original_nameobject_namets_name Droptime------------------------------ -------------------------------- ------------------------------ ----------------- ------------- -------------------EDU Test_flash bin$mfwmgr6pc/Lguweaah94la==$0USERS .-Geneva- -: -: A: Geneva
Found the flash back directly by name, flashback to the last deleted table
If you need to specify which table to flash back to can also be executed:
Table "bin$mfwmgr6pc/lguweaah94la= =$0todrop to Test_ flash_2;
Oracle Flash Back Technology-flashback removal