CacheSize property

Applies to
TQDB, TQDBItem, TQDBView

Declaration
property CacheSize : longint;

Description
The CacheSize property sets the size of the internal cache that is used to speed up access to items of data. The default value is 128K. You should choose a CacheSize that balances accomodation of a significant number of data items against consumption of memory. The CacheFrequency property or CacheStatistics method can be used to measure how succesful the cache is.

The item-cache stores as many items as will fit in the allotted memory. When the cache gets full as many items as necessary are removed to accommodate the new item. The items discarded first are among those least recently used.

N.B. Caching has its own overhead. If QDB's temporary files are stored on a ram (or other fast) drive caching may actually degrade performance. You should always check to see if the item cache is helping.