Posts

Showing posts with the label falshback #drop

How to get table back once it is deleted

  flashback table < table > to timestamp < when it was good>; flashback table orders to timestamp systimestamp - interval '1' hour ; alter table < table > enable row movement; select * from < table > as of timestamp systimestamp - interval '1' hour ; select * from < table > as of scn 1234567; insert into table    select * from < table > as of timestamp sysdate – interval '1' hour    where <conditions to find the rows >; select * from < table > as of timestamp sysdate – interval '1' hour minus select * from < table >; insert into < table >    select * from < table > as of timestamp sysdate – interval '1' hour    minus    select * from < table >; update < table > cur set (col1, col2, col3) = (    select col1, col2, col3 from < table >      as of timestamp systimestamp ...