SQL*PLUS transaction exited what happens [message #7564] |
Sun, 22 June 2003 02:16 |
shashi
Messages: 34 Registered: March 2001
|
Member |
|
|
Not sure if this question can be asked in this forum .
Any idea whats the answer to this question is?
When a transaction in being executed using SQL*PLUS tool and the tool is being closed down suddenly with out any commit or rollback given exclusively ,what will happen to the transaction
a)transaction is rolled back
b)transaction is commited
c)there wud be lock on the database resources used in this transaction.
d)none
Request you to give an explanation pls.
:-)
|
|
|
Re: SQL*PLUS transaction exited what happens [message #7574 is a reply to message #7564] |
Mon, 23 June 2003 03:57 |
Mahesh
Messages: 90 Registered: January 2001
|
Member |
|
|
for the above query it depends upon the setting of the environment variables..
by default it is rolled back.
if u want u can set the auto commit on by setting the environment variable in the menu as "currnet-on"
any better explanation always welcome
|
|
|
Re: SQL*PLUS transaction exited what happens [message #7581 is a reply to message #7574] |
Mon, 23 June 2003 11:00 |
shashi
Messages: 34 Registered: March 2001
|
Member |
|
|
Hmm.....ok ..but what about the below scenario->
I write a PL/SQL block with a commit statment in it.
I execute the block soon after which I disconnect the SQL*PLUS ,in this case the block wud get executed successfully with commit since the PL/SQL wud be running on the server.
Is this Valid ???
Mahesh will the environment variable have any role in the scenario explaned here.....
|
|
|
Re: SQL*PLUS transaction exited what happens [message #7591 is a reply to message #7564] |
Mon, 23 June 2003 22:13 |
Mahesh
Messages: 90 Registered: January 2001
|
Member |
|
|
shashireka...when we consider about ur scenario..
since u r performing the commit manually over here..
there is no role of envitonment variable in this scenario..
the environment variable come into scenario only when the window is closed abruptly and before closing no commit or rollback is given by the user..
where has for ur question alreasy a commit statement is executed in the above scenario
|
|
|