apache > db
Apache DB Project
 
Font size:      

Rollback

Rollback

Syntax

ROLLBACK 

Description

Issues a java.sql.Connection.rollback request. Use only if auto-commit is off. A java.sql.Connection.rollback request undoes the currently active transaction and initiates a new transaction.

Examples

ij> autocommit off;
ij> INSERT INTO menu VALUES ('dessert', 'rhubarb pie', 4);
1 row inserted/updated/deleted
ij> SELECT * from menu;
COURSE    |ITEM                |PRICE
-----------------------------------------------
entree    |lamb chop           |14
dessert   |creme brulee        |7
appetizer |baby greens         |7
dessert   |rhubarb pie         |4
 
4 rows selected
ij> rollback;
ij> SELECT * FROM menu;
COURSE    |ITEM                |PRICE
-----------------------------------------------
entree    |lamb chop           |14
dessert   |creme brulee        |7
appetizer |baby greens         |7
 
3 rows selected
ij>

Previous Page
Next Page
Table of Contents
Index