types of transaction in SQL

There are two types of transaction in sql
* Rollback
* Commit
commit:-
The commit statement terminate the current transaction and makes all changes under the transaction persistent. It commits the changes to the database.
General format of Commit
commit WORK is an optional keyword that does not change the semantics of COMMIT. ROLLBACK Statement:-
The ROLLBACK Statement terminates the current transaction and rescinds all changes made under the transaction. It rolls back the changes to the database. The ROLLBACK statement has the following general format: ROLLBACK [WORK]WORK is an optional keyword that does not change the semantics of ROLLBACK.

1 comment:

Plz Share your comments...