Subject Re: Generators don't works anymore
Author amoradell
Yes I know that the first and third statement don't change generator
value. But its a common shortcut to verify a generator value.

So, the problem is :
- does the insertion in columni table change generator value ?
- according to the trigger and if it's active (and probably so,
because columni.mycode is not null and unique), it should change.

for generators list, do you mean with isql ?

show generators

regards

Alexandre



--- In firebird-support@yahoogroups.com, "Adam" <s3057043@...> wrote:
>
> >
> > 1 - select (gen_comuni_id,0) from rdb$database : value
>
> This statement fails to call the gen_id function, and even if it did,
> it adds zero to gen_comuni_id then returns it. Why would you expect
> the value to change???
>
> Try:
> select gen_id(gen_comuni_id,1) from rdb$database
>
> That should return the next value every time it is called.
>
> Adam
>