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: Can Oracle do nested transactions?

Re: Can Oracle do nested transactions?

From: Heidi K. Barg <heidi_at_stepforward.org>
Date: 1998/06/10
Message-ID: <6ln1i3$p9a$1@cleavage.canuck.com>#1/1

This is a NESTED transaction in which the commit or rollback command should be coupled with the most recent begin. According to the pseudo example the begin on line 1 and rollback on line 7 are coupled together and also the begin on line 2 and commit on line 4 are coupled. When line 7 is executed it should roll the table back to the state at which it was at the time Line 1 was executed; thus, in effect uncommitting the commited data on line 4.

This is how it works in many other databases and is neccessary for example in Oracle for inserting blob fields that may need to be rolled back.

heidi_at_stepforward.org

Heidi K. Barg wrote in message <6lm7tr$eiv$1_at_cleavage.canuck.com>...
>If I do the following pseudo on an empty table:
>
>begin transaction
> begin transaction
> insert into table1 (a,b) values (1, empty_clob())
> commit transaction
> select b from table1 where a = 1 for update
> OCILobWrite(...)
>rollback transaction
>
>then, a row is inserted that contains a=1, and b=empty whereas it should
 not
>have any rows at all.
>
>I'm not sure if I am missing some sort of configuration variable or what
 I'm
>doing wrong.
>
>thanks,
> heidi
>
>
Received on Wed Jun 10 1998 - 00:00:00 CDT

Original text of this message

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