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

Home -> Community -> Usenet -> c.d.o.misc -> Re: keep select in transaction

Re: keep select in transaction

From: Michael Gast <mig-sm_at_web.de>
Date: Tue, 12 Apr 2005 09:21:33 +0200
Message-ID: <425b7739$0$292$4d4ebb8e@read.news.de.uu.net>


Hi Eitan,

Eitan schrieb:
> Hello,
> I want to open a transaction in oracle (9i),
> where first I declare a transaction,
> I want that any select will not be affected, as the database changes after I
> open the transaction.
>
> i.e :
>
> start transaction
> ....
> ' during this time rows were inserted to database in other transaction.
> ' I don't want that when I do the following select - I get the rows, that
> were inserted
>
> select * from table_that_was_changed_after_start_trans
> ' I don't want that the changes on the above tables will be seen on the
> result.
>
> commit transaction
>
> Thanks :)
>
>

as far as i remember Oracle works in 'read commited' mode per default. That means that you will 'see' rows inserted AND commited in other transactions within your transaction. What you need in this case is to set the transaction isolation level to 'serializable'.

And: Please don't cross post.

-- 
Mit freundlichen Grüßen / Best regards
Michael Gast
SEPP MED GmbH

All emails sent to this address are never read and never will be answered. 
Sorry, but until someone cleans up the spam mess, that's the way it has to be.

E-Mails, die direkt an diese Adresse geschickt werden, lese und beantworte ich 
nicht. Ich bedauere diesen Umstand sehr, kenne derzeit aber keine bessere 
Möglichkeit, um die Spam-Flut abzustellen.
Received on Tue Apr 12 2005 - 02:21:33 CDT

Original text of this message

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