Subject | Re: Maintaining proper generator values |
---|---|
Author | Alexander V.Nevsky |
Post date | 2003-11-12T09:58:16Z |
--- In firebird-support@yahoogroups.com, "soso_pub" <soso_pub@y...>
wrote:
Gen_Id(MyGen,:Inc) and Inc is calculated on some conditions. If
this calculation can erroneously result negative value... But in
general I agree and never encountered problems with generators myself.
Doug's approach IMHO is related not to normal database life but to
database maintenance after corruption, natural (power failure etc) or
artificial (programming or administration errors).
Best regards,
Alexander.
wrote:
> I followed the discussion briefly and I would like to add a point. Iand
> think that using _only_ the GEN_ID(...) function will not generate
> duplicate values, regardless of the number of concurent conections
> the step of the generator per connection. This is what I concludedtrouble.
> from the documentation of IB6 and this is how it should be.
> On the other hand, if you reset the value of the generator with SET
> GENERATOR to a smaller value than the current, this could cause
Gen_Id(MyGen,:Inc) and Inc is calculated on some conditions. If
this calculation can erroneously result negative value... But in
general I agree and never encountered problems with generators myself.
Doug's approach IMHO is related not to normal database life but to
database maintenance after corruption, natural (power failure etc) or
artificial (programming or administration errors).
Best regards,
Alexander.