oracle中恢复delete删除的数据

前端之家收集整理的这篇文章主要介绍了oracle中恢复delete删除的数据前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

手一抖数据就没了,/(ㄒoㄒ)/~~

查询Stable_name2018-05-28 10:10:00 时刻的数据,删除之前的时刻

SELECT * FROM Stable_name AS OF timestamp to_timestamp('2018-05-28 10:10:00','yyyy-mm-dd hh24:mi:ss');

筛选出被删除的数据

SELECT * FROM (SELECT * FROM Stable_name AS OF timestamp to_timestamp('2018-05-28 10:10:00','yyyy-mm-dd hh24:mi:ss'))

WHERE 筛选条件;

重新插入数据

insert into Stable_name (SELECT * FROM (SELECT * FROM Stable_name AS OF timestamp to_timestamp('2018-05-28 10:10:00','yyyy-mm-dd hh24:mi:ss'))

WHERE 筛选条件);

完毕。

原文链接:https://www.f2er.com/oracle/205937.html

猜你在找的Oracle相关文章