Flash-back processing method and device for database and electronic equipment
A processing method and database technology, applied in the computer field, can solve problems such as inaccurate database flashback processing, database modification, truncated table database operation errors, etc.
- Summary
- Abstract
- Description
- Claims
- Application Information
AI Technical Summary
Problems solved by technology
Method used
Image
Examples
Embodiment 1
[0035] see figure 1 A flashback processing method for a database is illustrated, and the method includes the following steps:
[0036] S101. Acquire a first operation instruction at a first moment.
[0037]Wherein, the first operation instruction is used to instruct the user to modify the database; the first operation instruction includes a truncate statement for truncating the first table in the database. The truncate statement can also be described as a truncate table statement, which is a structured query language (SQL) statement, which can be recorded as TRUNCATE TABLE XX; wherein, "XX" represents the name of the relevant table, and the truncate table statement can delete all the rows of the related table. In step S101, the truncate table statement acts on the first table, and can delete all rows in the first table. The first table may refer to any table file in the database.
[0038] Exemplarily, the database (database, DB) may be a relational database management syst...
Embodiment 2
[0052] In this embodiment, another database flashback processing method is introduced for the case where the database flashback needs to restore not only the truncated table, but also other operations such as delete, update, and insert.
[0053] Exemplary, see image 3 Another database flashback processing method is illustrated, and the method includes the following steps.
[0054] S301. Acquire a first operation instruction at a first moment.
[0055] The first operation instruction is used to instruct the user to modify the database; wherein, the first operation instruction includes a truncation statement for truncating the first table in the database. The definition of the truncated sentence can be understood with reference to S101, which will not be repeated in this embodiment of the present application.
[0056] In addition, the first operation instruction further includes a database manipulation language (data manipulation language, DML) type of statement, and the DLM ...
example 1
[0061] Example 1, the first operation instruction includes a truncate statement, an insert statement, an update statement, and a delete statement corresponding to the first table. Taking tb1 as the first table and executing statements one by one as an example, the first operation instruction can be divided into the following steps T1-T4 to execute.
[0062] T1, truncate tb1: truncate tb1;
[0063] T2, insert data into tb1: insert into tb2(id, name)values(3,'test3');
[0064] T3, update the data in tb1: update tb1 set name='test33' where id=1;
[0065] T4, delete some data in tb1: delete from tb1 where id=3 and name='test33'.
PUM
Login to View More Abstract
Description
Claims
Application Information
Login to View More 


