Is it a way to clear the cache of CacheCalcFields without reloading the data?

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Justmade
Posts: 108
Joined: Sat 16 Aug 2008 03:51

Is it a way to clear the cache of CacheCalcFields without reloading the data?

Post by Justmade » Sat 18 Mar 2017 04:04

CacheCalcFields is very nice feature to reduce redundant running of onCalcFields or Lookup.

However, there is some case which we need to clear the cache and let the onCalcFields/Lookup to rebuild the cache.

For example, I have many base tables containing name and basic inform for the other tables to lookup for. Regarding the Name fields it is actually a translated text based on the user's current language setting. When the user change language, all the text in name field need to be refresh for the new language. If I do not want to close and re-opened those base tables which unnecessarily reload all data from server, how can I clear the cache and let the tables to refresh all Calc/lookup field?

Thank you in advance for any help.

azyk
Devart Team
Posts: 1119
Joined: Fri 11 Apr 2014 11:47
Location: Alpha Centauri A

Re: Is it a way to clear the cache of CacheCalcFields without reloading the data?

Post by azyk » Fri 24 Mar 2017 09:00

In UniDAC there is no possibility to change the cached values CalcFields in dataset if it is open (TUniQuery.Active=True).

Post Reply