Subject | Re: [firebird-support] Generator limits |
---|---|
Author | Ann W. Harrison |
Post date | 2006-06-02T21:07:46Z |
Magni Thor Mortensen wrote:
they're going to be sequential. If a transactions gets a
generator value then fails to commit the record it stored -
or fails to store the record - the number is lost and you've
got a gap. There are several less efficient ways of generating
unique sequential numbers. Basically, they all require that
you serialize your inserts - one must be committed before the
next is stored.
Regards,
Ann
>A problem with generators is that you can't be certain that
> I must have a unique sequential tr number in table 2 and I thought it
> best to use generators to prevent conflicts.
they're going to be sequential. If a transactions gets a
generator value then fails to commit the record it stored -
or fails to store the record - the number is lost and you've
got a gap. There are several less efficient ways of generating
unique sequential numbers. Basically, they all require that
you serialize your inserts - one must be committed before the
next is stored.
Regards,
Ann