saved, or copy the data to another location in the database. Oracle provides a view ts_pitr_objects_to_bedropped that lists all objects that will be lost during the recovery operation. Use this view to determine the state of an object in a tablespace after it has been restored.
Sql> Col owner Format A10
Sql> Col name format A10
Sql> alter session set nls_date_format= ' Yyyy-mm-dd hh24:mi:ss ';
Sql> SELECT * from ts_pitr_objects_to_be_dropped WHER
To view a table in the Recycle BinSelect Object_name,original_name,partition_name,type,ts_name,createtime,droptime from RecycleBin;Recovery tableSql>flashback table Test_drop to before drop;Sql>flashback table "Bin$b+xkko1rs5k10uko9bfmua==$0" to before drop;Note: must be supported by version 9i or 10g, flashback cannot restore full-text indexThe following is a referenceEasily recover accidentally deleted tables using the Flash-back table feature in
----query for OCR status:
#/oracle/product/10g/crs/bin/ocrcheck
Prot-601:failed to initialize Ocrcheck
---------Replace the original OCR disk with an error:
#/oracle/product/10g/crs/bin/ocrconfig-replace OCR '/DEV/RDSK/C5T600A0B80005AD8BC0000020000000000D0S7 '
/oracle/product/10g/crs/bin/ocrconfig-replace ocrmirror '/dev/rdsk/c5t600a0b80005ad8bc0000020000000
As a programmer, database operation is necessary, but if the operation is wrong, generally will cause more serious consequences.
Today, accidentally, did a worried thing, will be using the organization of the wrong operation of the delete, suddenly the brain a little hypoxia, feeling a circle (I believe that no data backup and rollback experience of the small partners are such feelings), but a think, the database is generally supporting data rollback, Then look up the solution.
Because
finally begins with the English letter, do not take Chinese charactersNtries represents the maximum number of super users allowed. This is an optional one. The first two must be specified. It is generally set to be larger than the actual need to avoid enough.After success, restart Oracle, login sys and password, remember the password must be followed by as SYSDBA, I am open PL/SQL command window with conn sys/password as SYSDBA login!I then successfu
At some point, it's easy to accidentally delete stored procedures, so the stored procedures are deleted, how do we recover? Here for you to explain.
1. Create a test stored procedure
Sql> Conn Roger/roger
Connected.
sql> CREATE OR REPLACE PROCEDURE proc_test_drop
2 AS
3 BEGIN
4 for X in (SELECT sysdate from dual)
5 LOOP
6 Dbms_output.put_line (x.sysdate);
7 End LOOP;
8 End Proc_test_drop;
9/
Procedure created.
Sql> set Serveroutput on
s
;alter Database Flashback onSql>flashback database to SCN Scnno;Sql>flashback database to timestamp to_timestamp (' 2007-2-12 12:00:00 ', ' yyyy-mm-dd hh24:mi:ss ');Summarize:Oracle provides the above mechanisms to ensure safe operation, but also for the generation of another problem, is the space occupancy, due to the operation of the above mechanism, using the drop of a table or delete data, the space will not be automatically reclaimed, for some to determine the unused table, delete the same
the Recycle Bin to clean up the tables in the Recycle Bin according to the FIFO principle. Of course, you can also manually clean up the specified table:Purge table recycletest;Or use the name of the object in the Recycle Bin:Purge table "bin$04lhcpndanfgmaaaaaanpw==$0";This command clears out all objects related to the table, including indexes, constraints, triggers, and so on. If you want to permanently delete an index, you can:Purge index in_test_01;This command simply deletes the index of t
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.