1.时间闪回
select * from JS_YWFSRZ as of timestamp to_timestamp('2017/04/13 10:17:00','yyyy/mm/dd hh24:mi:ss')
2.版本闪回
select versions_startscn,
versions_starttime,
versions_endtime,
versions_operation,
versions_xid
from JS_YWFSRZ
versions between timestamp to_timestamp('2017/04/13 10:20:00', 'yyyy/mm/dd hh24:mi:ss') and to_timestamp('2017/04/13 10:30:00', 'yyyy/mm/dd hh24:mi:ss')
3.表根据时间返回
因为未启用行移动功能 不能闪回表
Flashback table pb_acc_user to timestamp to_timestamp
('2014-0315 09:30:00','yyyy-mm-dd hh24:mi:ss');
提示ORA-08189: 因为未启用行移动功能, 不能闪回表 。一般来说出现这种错误,就是数据库表不支持闪回功能,修复很简单,开启即可。
所以执行以下语句 再执行闪回
alter table pb_acc_user enable row movement;
成功闪回修改.
4.表根据scn 返回
flashback table test to scn 13793458;