In Delphi applications, the use of tables containing fields that autoincrement, or change automatically in some manner unknown to the application, can be problematic.Paradox, Inter Base, Sybase and Informix tables all provide means of inserting or updating field values automatically, without intervention from the front- end application.Not every table operation is affected by this mechanism, however.

delphi data aware controls not updating-37

The three areas that are affected by these field types are simple inserts, batchmoves, and table linking.

Handling Update and/or Append Batch Moves ----------------------------------------------------------------- Paradox Tables Since the Autoincrement field type is a read-only type, attempting to perform a batchmove operation with such a column in the destination table may cause an error.

To circumvent this, the TBatch Move components Mappings property must be set to match source table fields to the target destination fields excluding the destination table's Autoincrement field.

Serial columns differ from Paradox Autoincrement fields in that their values may be changed, while Autoincrement columns are read-only.

Inter Base and MS/Sybase SQL Server tables do not support a special type for this kind of behavior, but may employ triggers to accomplish the same task.

Triggers are specialized procedures that reside on the database server and automatically execute in response to events such as table inserts, updates and deletes.The use of tables with associated triggers can be particularly problematic, since triggers are capable of doing much more than just incrementing column values.For each table type, a different mechanism provides this behind-the-scenes behavior.Paradox tables support an Autoincrement field type.When new records are added to such tables, the Borland Database Engine determines the highest current value in that column, adds one, and updates the new row with the new value.For Informix tables, this behavior is provided by an Informix-specific field type called Serial.