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: How to generate unique document number ?

Re: How to generate unique document number ?

From: <krislioe_at_gmail.com>
Date: 12 Sep 2006 20:35:02 -0700
Message-ID: <1158118502.187488.201160@h48g2000cwc.googlegroups.com>


Sorry, I mean there should not be any gap.

krislioe_at_gmail.com wrote:
> Hi All,
>
> We need to generate Document Number where there should be any gap, so
> that we cannot use sequence. For example : Invoice Number.
>
> one possible approach like : Select MAX(InvoiceNumber)+1 from invoice,
> what if that table has millions of rows, is this reliable enough ?
> How to avoid two user do the same query at same time that lead to
> dupplicate number ?
>
> Anybody has done it this way in production? or any other approach ?
>
> Thank you for your info,
> xtanto
Received on Tue Sep 12 2006 - 22:35:02 CDT

Original text of this message

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