Remember once the database accidentally batch update recovery of the SAO operation

Source: Internet
Author: User

Based on a broken platform text editor, wrote a "; +" does not appear the compilation exception, the code executes directly, resulting in a "+" after the "where" condition did not use the ~ batch update the Contract table, very helpless, but also very fortunate to review the discovery of this huge horror of things, once again refreshed me a program dog three views!!!

The first thing is to shut down the server and then export the data, backup, import and export commands as follows:

Export: EXP  zzmes/[email protected] buffer=4096 owner=zzmes file=f:\zzmes20170114.dmp           user    password    database connection to export import: IMP zzmes/[email protected] buffer=30720 fromuser=zzmes touser=zzmes file= f:\ Zzmes20170114.dmp          user    password    to import to the database        export user to export      a file that the user has exported

And then found on the Internet the following command to recover data, specific can refer to the following blog: http://vvv-110.iteye.com/blog/2072702, but must be restored as soon as possible, and must be backed up in advance to prevent two injuries, you understand ...

First, execute the following SQL to restore data from the Test_temp table to 2014 05 28 11:00:00

Note that this must first delete all data, otherwise it may lead to duplication of data, I use the first kind, to do ~

from SELECT * from as of timestamp to_timestamp ('       2014-05-28 11:00:00','yyyy-mm-dd hh24:mi:ss') commit;

Second, the following:

Select timestamp_to_scn (To_timestamp ('2014-05-27 11:00:00','  YYYY-MM-DD HH:MI:SS' from dual;
from Sys.smon_scn_time order by time_dp Desc;
71547785
Then Selectfrom71547785

Three, the following:

Select  from
The data found through this statement is limited because some users may have disconnected the Oracle connection

Recently the mood is very irritable, so bad ~ more and more worrying things, do their own not cool, do better their own cool ~

  

Remember once the database accidentally batch update recovery of the SAO operation

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.