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: about sequence in oracle

Re: about sequence in oracle

From: Galen Boyer <galenboyer_at_hotpop.com>
Date: 14 Aug 2001 15:34:11 -0500
Message-ID: <uk806z07l.fsf@verizon.net>

On Mon, 13 Aug 2001, howardjr_at_www.com wrote:

> In the past, when confronted with this problem, I've created a
> table which holds the next sequence number as a plain old
> number. An insert into table A also generates an update on
> table Z set sequA = sequA+1, and a rollback thus undoes both
> bits of DML. The next insert therefore finds the sequence
> number at the right value.

But, how while the number is being incremented by process A, process B could be querying and then they both get the same number. Did you temporarily lock the rows, maybe select for update?

-- 
Galen Boyer
It seems to me, I remember every single thing I know.
Received on Tue Aug 14 2001 - 15:34:11 CDT

Original text of this message

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