Oracle database generates misoperation, empty a field, recovers data

Source: Internet
Author: User
Tags uuid

The work of the time did not carefully check the SQL directly executed, the data on the line is mistaken, found to grasp the changes, fortunately, only modified a table column;

On the Internet, Oracle can query data for 24 hours at any time.

SELECT * FROM BTGL_YLBT_SQB t as of timestamp to_timestamp (' 2018-01-24 10:56:00 ', ' yyyy-mm-dd hh24:mi:ss '); --Query to this time data

-To restore this column to this moment

Update BTGL_YLBT_SQB SQB
Set sqb.duration =
(select Duration from BTGL_YLBT_SQB as of timestamp to_timestamp (' 2018-01-24 10:56:00 ', ' yyyy-mm-dd hh24:mi:ss ') a
where sqb.uuid = A.uuid);

Fortunately there is a solution, or this is an accident Ah!

Oracle database generates misoperation, empty a field, recovers data

Related Article

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.