Subject Re: (unknown)
Author rjkjfloyd
I created this generator using the DSQL through the connection as
follows

create generator RCRECEIPTNO_GEN (this is just like the example in
the data definition guide)

I have tried different case such as RCReceiptNo_GEN or
rcreceiptno_gen and any other cominbination I can think of. When I
look at the list of generators it shows as all caps.

I am saving the value of the generator into a field in my setup
record and I set that field up as a numeric because the data
definition guide says the column that holds the generated value must
be defined as numeric or decimal.

How do you query the system tables? Or where can I look for
directions on how to query the system tables?

As always thanks for the great support.

Kristy


--- In IBObjects@y..., Helen Borrie <helebor@d...> wrote:
> At 03:55 PM 28-01-02 +0000, you wrote:
> >Hi All!
> >
> >I am working on a form where I need to get the value of the
generator
> >and put it in a variable to display in an edit box on the form. I
am
> >using the generator as a receipt number and want to allow the user
to
> >change the receipt number(receipt number is not the key to the
> >file). They can then edit the number and I can set the generator
to
> >the new value.
> >
> >The problem is that my sql code is saying the my generator is not
> >defined.
>
> Kristy,
> That message means the generator is not defined! Did you create
the generator using a tool that double-quotes identifiers? In that
case, the name of the generator will be case-sensitive. You'll need
to query the system tables or view the metadata through a tool to
check the correct case of everything.
>
>
> >UPDATE Form SET Variable = GEN_ID(Generator_GEN,0) WHERE FILEKEY =
1
> >
>
> By the way, when you fix this problem, the next one will likely be
key violations on the unique constraint on your invoice number. Your
approach here isn't multi-user-safe...
>
> regards,
> Helen
>
>
> All for Open and Open for All
> Firebird Open SQL Database ยท http://firebirdsql.org
> _______________________________________________________