Subject Re: generator of generators
Author Alexander V.Nevsky <>
--- In, "duilio_fos <irel_llc@l...>"
<irel_llc@l...> wrote:
> Svein,
> > the one thing that bothers me is that you want to do DDL from
> within your application
> it sounds cumbersome to me, too.
> That's why I posted the original message, but I see no other way to
> solve the problem.
> > The one article that I think may get you on a better track is "An
> Auditable Series of Numbers"
> it is more or less what I have to do, but _for N different

Duilio, I had one time similar problem with internal company
documents numbers - no strong requirements for absence of holes and
security, but users wanted different successions for departments just
for psychological comfort. I could'nt solve it without performance
degradation or ladder of if-then-else in insert triggers which should
be modified each time new department is created. Be ready any other
than generators technique will be possible bottleneck in performance.
Seems new Execute Statement feature of FB1.5 is what you are searching
for, last redaction already can return values, in your case -
generator value. Did'nt tested it yet myself, naturally it should be
slower than pre-compiled statement, but I hope less slower than
waiting for conflicts on record-based emulation of generators. Of
course I mean generator usage, not creation - this should be made by
client statement on company registration. But neverthelles it can't be
used for Auditable Series of Numbers because of
transaction-independent nature of generators - they can't be rolled
back with transaction.

Best regards, Alexander V.Nevsky.