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 -> Sequence number availability to others during transaction

Sequence number availability to others during transaction

From: Paul Cloud <PaulCloud_at_dialaccess.com>
Date: 2000/05/06
Message-ID: <QO%Q4.1052$Jf.3947@newsfeed.slurp.net>#1/1

Hello everybody,

I have a stored procedure running on Oracle 7.3.4, that does one or more inserts into a table where the primary key is a sequence number. The procedure also does some other table updates, too. At the end of the procedure, I want to commit all transactions, or rollback if there was an error at some pont in the processing. If two or more users execute this procedure at or about the same time, the second user receives a -0001 (dup value on index) error, which I believe is due to the fact that the transactions for user 1 have not been commited at the time user 2 tries to do the same processing, and they are both trying to insert using the same sequence numbers. I don't think a savepoint after the inserts will "publish" the new sequence so that other users will use the "new, revised" sequence, but I could be wrong. Does anybody know how to solve this?

Thanks,
Paul Received on Sat May 06 2000 - 00:00:00 CDT

Original text of this message

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