Subject Re: [IBO] GEN_ID: trigger does not seem to fire
Author Helen Borrie
John,

This list provides support for IB Objects, not IBX, which is a different and incompatible component suite. IBO has full support for generators and will do what you need.

If you plan to stay with IBX rather than use IBO to get the benefits of foundation-level support for InterBase/Firebird, you will possibly find solutions by joining the interbasexpress newsgroup on the Borland news forum.

Regards,
Helen

At 12:45 AM 02-08-01 +0000, you wrote:
>I have created a Generator and the Trigger and they both exist in the
>database.
>
>CREATE GENERATOR UNIGEN;
>
>SET TERM !! ;
>CREATE TRIGGER UNIKEY FOR UNIVERSAL
>BEFORE INSERT POSITION 0
> AS BEGIN
> NEW.KEYNO = GEN_ID(UNIGEN, 1);
> END !!
>SET TERM ; !!
>
>The problem is when I insert the record the 'KEYNO' is NULL. I am
>using IBX components in Delphi v5 enterprise.
>
> tUniversal.Insert;
> tUniversal['fName'] := 'BOB';
> tUniversal.Post;
>
>I hope someone will assist me with this problem.
>
>John Hart.

All for Open and Open for All
InterBase Developer Initiative ยท http://www.interbase2000.org
_______________________________________________________