ROLLBACK

1.   ROLLBACK undoes all uncommitted DML changes made in the current transaction and restores the data to the last committed state.

2.   After ROLLBACK, the changes made in the current transaction are not visible to any session, including the session that performed them.

3.   ROLLBACK releases all row-level locks held by the transaction, allowing other users to access and modify the affected rows.

4.   Once a rollback is issued, all uncommitted changes are permanently discarded and cannot be recovered.

5.   If a ROLLBACK is not issued and the session ends abnormally, Oracle automatically rolls back the uncommitted changes.

6.   ROLLBACK can be used to undo changes made after the last COMMIT, but it cannot undo changes that were already committed.

7.   Oracle does not automatically roll back after DML; an explicit ROLLBACK is required unless the session terminates unexpectedly.

8.   ROLLBACK does not affect committed data or changes made by other sessions.

9.   ROLLBACK can be used with SAVEPOINT to undo part of a transaction while keeping earlier changes.

10.  After a ROLLBACK, the current transaction is ended, and Oracle starts a new transaction for subsequent DML operations.

No comments:

Post a Comment