Subject Re: Is some API to get generator value?
Author emb_blaster
--- In firebird-support@yahoogroups.com, Lester Caine <lester@...> wrote:
>
> karolbieniaszewski wrote:
> >> Are there real situations when you might need to know a generator value
> >> > without using it in a transaction?
> >> >
> > Generator can be used for some other conditions
> > 1. as database settings
> > 2. as replacement for events - you can inc generator value in some conditions eg. some client interest tables are modified.
> > Client read in some interval generator value if is different then previous then data should be refreshed
> > 3 ..
> > 4..
> >
> > i suppose more examples can other users show
>
> But in those examples you still need a connection and a default transaction to
> do any reading makes sense.

Not at all. Karol has pointed is that you could check the sequence for modifications and THEN refresh. But that doesn't will need a transaction at all if theres NO modification.

Anyway, IMHO, events FTW! :)