Page 1 of 1

Problem with Autoinc And TZQuery

Posted: 10.10.2007, 19:10
by Capello
Hello,
I have a problem with Autoinc field. In my project I use Delphi 5, Firebird2.0 and Zeos 6.6.0 beta.
using TZQuery And TZUpdateSQL to insert record into table with primary key type AutoInc. when I post I recieve error (AutoInc field not assigned and is null).
I need your help. Thanks

Posted: 10.10.2007, 19:23
by ssamayoa
Autoinc fields don't exists on Firebird, you must provide from client side (before post is a good point to put it) or server side must provide it via before insert trigger.

If you have a before insert trigger to set the "autoinc" field, I suspect you have persistent fields for your TZQuery. Set "Required" to false in the "autoinc" field.

Regards.

Posted: 10.10.2007, 19:25
by ssamayoa
Sorry, I wrote in a hurry and omit a few words:

"Autoinc fields don't exists on Firebird, you must provide field value from client side (before post is a good point to put it) or server side via before insert trigger."

Regards.

Posted: 10.10.2007, 22:48
by mdaems
Capello,

Have a look here : http://zeos.firmos.at/viewtopic.php?t=1257

Mark