快速恢复delete数据

要注意的是,最好打开归档模式,否则可能空间不够

一:根据时间恢复

select * from temp;

delete from tempwhere EMPNO=7369;

查询当前电脑时间:

select to_char(sysdate,'yyyy-mm-dd hh24:mi:ss')from dual;

查询删除之前数据:

select * from tempas of timestamp to_timestamp('2018-04-12 09:12:11','yyyy-mm-dd hh24:mi:ss');

恢复数据:

flashback table tempto timestamp to_timestamp('2018-04-12 09:12:11','yyyy-mm-dd hh24:mi:ss');

若出现报错:ORA-08189:未启用行移动功能,不能闪回表;

则:

alter table temp enable row movement;

posted @ 2019-11-08 09:26  update_  阅读(958)  评论(0编辑  收藏  举报