Determining if you Need to Control the Updating Process

From InterBase

Go Up to Controlling the Update Process


Some of the time when you use cached updates, all you need to do is call ApplyUpdates to apply cached changes to the base tables in the database. In most other cases, however, you either might want to or must provide additional processing to ensure that updates can be properly applied. Use a handler for the updated dataset component’s OnUpdateRecord event to provide this additional processing.

For example, you might want to use the OnUpdateRecord event to provide validation routines that adjust data before it is applied to the table, or you might want to use the OnUpdateRecord event to provide additional processing for records in master and detail tables before writing them to the base tables.

In many cases you must provide additional processing. For example, if you access multiple tables using a joined query, then you must provide one TIBUpdateSQL object for each table in the query, and you must use the OnUpdateRecord event to make sure each update object is executed to write changes to the tables.

The following sections describe how to create and use an TIBUpdateSQL object and how to create and use an OnUpdateRecord event.

Advance To: