Subject | Re: [IBO] GSG030. Generators and Master/Detail tables. |
---|---|
Author | Jason Wharton |
Post date | 2002-10-12T02:41:15Z |
You should make the trigger only assign a value from a generator if the
NEW.COLVAL IS NULL and then in IBO put a setting in the GeneratorLinks tab
so that it will grab a value from the generator upon going into insert
state. Keep in mind if you cancel the insert or if it otherwise fails that
generator value is lost. There is a whole TI sheet dedicated to generating a
contiguous series of numbers on the web-site if you need that.
Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com
-- We may not have it all together --
-- But together we have it all --
NEW.COLVAL IS NULL and then in IBO put a setting in the GeneratorLinks tab
so that it will grab a value from the generator upon going into insert
state. Keep in mind if you cancel the insert or if it otherwise fails that
generator value is lost. There is a whole TI sheet dedicated to generating a
contiguous series of numbers on the web-site if you need that.
Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com
-- We may not have it all together --
-- But together we have it all --
----- Original Message -----
From: "Raymond Kennington" <raymondk@...>
To: "IBObjects" <ibobjects@yahoogroups.com>
Sent: Monday, October 07, 2002 8:51 AM
Subject: [IBO] GSG030. Generators and Master/Detail tables.
> If the master table has a generator for its primary key field how is a
child record going
> to know what its reference field value is to be if the generated key is
calculated in an
> insert trigger?
>
> What is the IBObjects way of handling generators when inserting records
into both a master
> grid and a detail grid?
> --
> Raymond Kennington
> Programming Solutions
> W2W Team B