RecNo is quite slow

Discussion of open issues, suggestions and bugs regarding Virtual Data Access Components for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Domenico Mammola
Posts: 1
Joined: Wed 02 Jul 2008 09:04

RecNo is quite slow

Post by Domenico Mammola » Wed 02 Jul 2008 09:15

Hi! I'm making some performance tests on the virtual table component. Compared to other in-memory datasets (KbmMemTable and DxMemData) I found that VirtualTable has a lower memory footprint and it's faster in editing and posting but it's much slower while browsing records through the RecNo property.

Will this feature be improved in next releases?

Domenico

Antaeus
Posts: 2098
Joined: Tue 14 Feb 2006 10:14

Post by Antaeus » Thu 03 Jul 2008 07:56

There is no simple ways to optimize this functionality. So it is unlikely that it will be done in the nearest future.
As a possible alternative I can suggest using Locate by ordered dataset:

Code: Select all

  VirtualTable.IndexFieldNames := 'Number';  // perform ordering by a field we need 
  ...
  VirtualTable.Locate('Number', 25, []);
  ...
  VirtualTable.Locate('Number', 12, []);

Post Reply