Subject Re: [ib-support] 2 identical numbers from the same generator ?
Author Helen Borrie
At 10:04 AM 25-05-02 +0200, you wrote:
>I wrote an invoice application.
>2 PCs print invoices at the same time.
>The invoice number is given by the following stored procedure
> (result integer)
> result=GEN_ID(FAT_GEN, 1);
>In some infrequent cases 2 different invoices printed by the 2 PCs come out
>with the same invoice number.
>To be honest, it never happened in front of me.
>I am just shown 2 invoices with the numbers corrected by hand.
>I could not test fully the possibility that the 2 operators do something
>weird with the program (that allows an invoice to be reprinted, for instance).
>But before I start a thorough investigation, the question is : is there the
>least possibility (or a known bug) that allows a generator to release the
>same number to 2 different transactions ?

No, never. Whatever it is that you are seeing, it is not two identical
numbers both drawn from calls to Gen_id(theGenerator, 1).


All for Open and Open for All
Firebird Open SQL Database · ·