Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Autonomous Transactions

Re: Autonomous Transactions

From: <devjnr_at_gmail.com>
Date: 28 Aug 2006 05:44:04 -0700
Message-ID: <1156769044.230889.194260@h48g2000cwc.googlegroups.com>


Serge Rielau ha scritto:

> Could it be you have an MS SQL Server background?

Sure I have :)

> In Oracle (and DB2 FWIW) transactions are always global.
> If you want to open a new nested scope to be rolled back individually
> you use a save point.

You mean that I always have to explicitly commit or rollback sql commands before the use of a proc that should have commit or rollback inside itself?

case 1:



begin

if .... then
-- some insert
commit;
else
-- some other things
rollback;
end if

proc1; -- contains commit for other things

end;


case 2:



begin

proc1; -- contains commit for other things

if ... then
rollback; -- this rollback won't work?
end if

end;


Am I understanding well now?

thx to all. Received on Mon Aug 28 2006 - 07:44:04 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US