YMatrix
Quick Start
Cluster Deployment
Data Model
Data Writing
Data Query
SQL Reference
Maintenance and Monitoring
Tool Guide
Troubleshooting
Destroy a previously defined savepoint.
RELEASE [SAVEPOINT] savepoint_name
RELEASE SAVEPOINT destroys a save point previously defined in the current transaction.
Destroying the save point makes it impossible to use as a rollback point, but it has no behavior visible to other users. It does not undo the effect of commands executed after a savepoint is established. (For this purpose, see ROLLBACK TO SAVEPOINT.) Destroying a savepoint when it is no longer needed may cause the system to recycle some resources before the transaction ends.
RELEASE SAVEPOINT will also destroy all save points created after the specified save points are created.
savepoint_name
Create and then destroy a save point:
BEGIN;
INSERT INTO table1 VALUES (3);
SAVEPOINT my_savepoint;
INSERT INTO table1 VALUES (4);
RELEASE SAVEPOINT my_savepoint;
COMMIT;
The above transactions will be inserted 3 and 4 at the same time.
This command complies with SQL standards. This standard specifies that the keyword SAVEPOINT is required, but the YMatrix database allows it to be omitted.