August 1999
Intermediate to advanced
1488 pages
72h 53m
English
database.rollbackTransaction()
The rollbackTransaction() method of the database object will undo all actions performed since the last beginTransaction() method call.
Note
You cannot have nested transactions.
Listing 8.50 takes a commit field sent to the application from the user. If this evaluates to TRUE, the transaction is committed. If not, it is rolled back.
<SERVER> // See if the user wants to commit the last transaction client.commit = request.commit; if(client.commit = "YES"){ // Commit the transaction myConn.commitTransaction(); }else{ // Rollback the transaction myConn.rollbackTransaction(); ... |
Read now
Unlock full access