Subject | RE: [IBO] Auto-Incrementing Key Field |
---|---|
Author | Jack Cane |
Post date | 2002-10-14T01:10:35Z |
Frank,
OK, in the GeneratorLinks property of the tDataSource I added
TableName.FieldName = GeneratorName. In the DDL for the table I added "or
(FieldName=0)", which was not present in the DDL script, only
"(FieldName=null)".
Looks like that succeeded.
Vielen Dank!
jwc
-----Original Message-----
From: Frank Ingermann [mailto:frank@...]
Sent: Sunday, October 13, 2002 3:30 PM
To: IBObjects@yahoogroups.com
Subject: Re: [IBO] Auto-Incrementing Key Field
Hi Jack,
Jack Cane wrote:
( entries in the form "mytable.myidcolumn=mygeneratorname" )
- if you have a "Before Insert" trigger on that table, does it have
"if ((myidfield is null) or (myidfield=0)) then
myidfield = gen_id(myidgenerator,1);"
in it?
(take a look at http://www.fingerbird.de/generatorguide.htm for more
detailed
info on the subject of autoinc fields in Fb/IB, esp. with IBO.)
hth,
fingerman
--
-------------------------------------------------------------------------
when parsers parse, and compilers compile, then why don't objects object?
fingerbirdy - fingerman's door to Firebird
http://www.fingerbird.de
Yahoo! Groups Sponsor
ADVERTISEMENT
___________________________________________________________________________
IB Objects - direct, complete, custom connectivity to Firebird or
InterBase
without the need for BDE, ODBC or any other layer.
___________________________________________________________________________
http://www.ibobjects.com - your IBO community resource for Tech Info
papers,
keyword-searchable FAQ, community code contributions and more !
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
[Non-text portions of this message have been removed]
OK, in the GeneratorLinks property of the tDataSource I added
TableName.FieldName = GeneratorName. In the DDL for the table I added "or
(FieldName=0)", which was not present in the DDL script, only
"(FieldName=null)".
Looks like that succeeded.
Vielen Dank!
jwc
-----Original Message-----
From: Frank Ingermann [mailto:frank@...]
Sent: Sunday, October 13, 2002 3:30 PM
To: IBObjects@yahoogroups.com
Subject: Re: [IBO] Auto-Incrementing Key Field
Hi Jack,
Jack Cane wrote:
> I have configured the key field as an auto-incementing integer. I haveit
> hooked to a tdbEdit whose read-only property is set to true. When Ipress
> the 'Post' button of my tdbNavigator an exception is raised withmessage,
> "(Field name) is a required field".purpose of
>
> I can write some code to update the tdbEdit, but that defeats the
> the auto-incrementing feature. Is there a property to be set, which- did you set the GeneratorLinks property accordingly?
> automates this process?
>
> tks,
>
> jwc
( entries in the form "mytable.myidcolumn=mygeneratorname" )
- if you have a "Before Insert" trigger on that table, does it have
"if ((myidfield is null) or (myidfield=0)) then
myidfield = gen_id(myidgenerator,1);"
in it?
(take a look at http://www.fingerbird.de/generatorguide.htm for more
detailed
info on the subject of autoinc fields in Fb/IB, esp. with IBO.)
hth,
fingerman
--
-------------------------------------------------------------------------
when parsers parse, and compilers compile, then why don't objects object?
fingerbirdy - fingerman's door to Firebird
http://www.fingerbird.de
Yahoo! Groups Sponsor
ADVERTISEMENT
___________________________________________________________________________
IB Objects - direct, complete, custom connectivity to Firebird or
InterBase
without the need for BDE, ODBC or any other layer.
___________________________________________________________________________
http://www.ibobjects.com - your IBO community resource for Tech Info
papers,
keyword-searchable FAQ, community code contributions and more !
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
[Non-text portions of this message have been removed]