Performance of posting data to dataset

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
ply
Posts: 11
Joined: Tue 27 May 2008 15:03

Performance of posting data to dataset

Post by ply » Mon 05 Apr 2010 20:40

I have TUniQuery (SELECT 0 as checkbox, * FROM table1) with CachedUpdates=true
+ datasource + grid (Devexpress cxgrid)
In grid I just need to show readonly data and 1 editable column with checkboxes

When I click on checkbox, data posts to dataset, but it is very slow (about 500ms).
I dont need to save data or edit any columns except checkboxes.
How can I improve performance?

bork
Devart Team
Posts: 649
Joined: Fri 12 Mar 2010 07:55

Post by bork » Wed 07 Apr 2010 11:41

If you are using cashed updates mode to update your TUniQuery, then any updates will be saved to database on calling the ApplyUpdates method only.

So possible reasons for slow record updating are:

- Maybe some event on updating is being executed slowly. Try to remove all events from this query and try to update your record again.

- Maybe some event on redrawing your grid is being executed slowly. Try to remove all events from your grid and try to update your record again.

- Maybe some RefreshOptions are turned on and after each update a refresh query is executed. Try to turn off all RefreshOptions.

- Maybe Devexpress CXGrid has very complex view or calculates a lot of summary values. It can slow down record updating. Try to update your record by standard TDBGrid.

Try to apply all four pieces of advice at the same time and I believe you issue will be resolved.

Post Reply