Emil Moise
Emil Moise

Reputation: 393

Oracle - what happens with the transaction in case of ORA-03135 connection lost?

I need to run on production environemnt a delete statement that takes a lot of time and the server is closing any connection after 30 minutes (ORA-03135 from what I see in the logs).

What will happen if I start the delete statement and the server will close the connection? Will the statement finish executing on the server or will it shut it down immediately and rollback? Can SQL*Plus set autocommit on command help in this case?

Upvotes: 0

Views: 1354

Answers (1)

krokodilko
krokodilko

Reputation: 36107

Check the manual:https://docs.oracle.com/database/121/CNCPT/transact.htm#CNCPT037

End of a Transaction
A transaction ends when any of the following actions occurs:

  • A user issues a COMMIT or ROLLBACK statement without a SAVEPOINT clause.
  • A user runs a DDL command such as CREATE, DROP, RENAME, or ALTER.
  • A user exits normally from most Oracle Database utilities and tools, causing the current transaction to be implicitly committed. The commit behavior when a user disconnects is application-dependent and configurable.
  • A client process terminates abnormally, causing the transaction to be implicitly rolled back using metadata stored in the transaction table and the undo segment.

Upvotes: 2

Related Questions