|
AnyDAC
|
Specifies whether dataset will log changes to the data without immediate applying of them to the database.
CachedUpdates enables (True) or disables (False) the logging of data changes (Insert/Post, Edit/Post, Delete) without immediate applying of them to the database.
An application must explicitly apply changes from change log to the database, using ApplyUpdates method. All changes will be written in comparably small amount of time in single transaction. The main benefits of enabling cached updates are:
The potential drawbacks of enabling cached updates are:
Note, to change CachedUpdate property value for TADTable, it must be inactive.
property CachedUpdates: Boolean;
Caching Updates, ApplyUpdates, CancelUpdates, CommitUpdates
ADQuery1.CachedUpdates := True; ... ADQuery1.Edit; ... ADQuery1.Post; ... ADQuery1.Append; ... ADQuery1.Post; ... ADQuery1.ApplyUpdates; ADQuery1.CommitUpdates; ADQuery1.CachedUpdates := False;
|
What do you think about this topic? Send feedback!
|