Skip to main content Skip to complementary content

Clearing the Qlik Web Connectors cache

Some connectors cache the data locally, improving the load time after the initial download of data, and reducing the number of API calls. Over time it becomes necessary to clear or compress the cached data.

Clearing the cache manually

To delete the data cached for a connector, do the following:

  1. After selecting the connector, click on the Settings tab.
  2. In General Connector Settings click on the Clear Cached Data button.
  3. Confirm the deletion by clicking OK.
  4. A Cache cleared message should appear. Click OK.

Clearing the cache using a load script

You can clear the cache in your load script by using the following:

ClearCache: LOAD QlikWebConnectors_ClearCache_Result, QlikWebConnectors_ClearCache_SearchPattern, QlikWebConnectors_ClearCache_NoItemsDeleted FROM [http://localhost:5555/data?connectorID=CONNECTORS_NAME&clearcache=true] (txt, utf8, embedded labels, delimiter is '\t', msq);

You just need to replace CONNECTOR_NAME with the correct value. This is the value present in the same location in the URL in the other load statements you use for this connector.

For example, when you are fetching data from a account, you can place this as the first statement in your load script, perhaps running it conditionally based on the number of days since your last reload.

ClearCache: LOAD QlikWebConnectors_ClearCache_Result, QlikWebConnectors_ClearCache_SearchPattern, QlikWebConnectors_ClearCache_NoItemsDeleted FROM [http://localhost:5555/data?connectorID=FacebookInsightsConnector&clearcache=true] (txt, utf8, embedded labels, delimiter is '\t', msq);

Pattern matching

Some connectors support an additional parameter:

&clearcache_searchPattern=

Here you can pass in a string with * wildcards to further specify which cached items are to be deleted. Currently only the Facebook Insights support this , using:

clearcache_searchPattern=[pagename_or_id]

So, for example, to clear all the cached items for the QlikView Facebook page use:

ClearCache: LOAD QlikWebConnectors_ClearCache_Result, QlikWebConnectors_ClearCache_SearchPattern, QlikWebConnectors_ClearCache_NoItemsDeleted FROM [http://localhost:5555/data?connectorID=FacebookInsightsConnector&clearcache=true&clearcache_searchPattern=qlikview_*] (txt, utf8, embedded labels, delimiter is '\t', msq);

Deleting items older than X hours

You can use the parameter:

&clearcache_ageInHours=X

where X is an integer greater than or equal to zero. If this is specified, then only items older than this will be deleted.

Compressing the Cache folder

A large number of files can accumulate in the cache directory and for this reason we would recommend configuring Windows to compress the folder.

By default the Qlik Web Connectors cache is located in the Data folder in the Qlik Web Connectors folder created when during installation. For example if Qlik Web Connectors is located in the folder C:\QlikWebConnectors\, then the cache for each connector will be located at:

C:\QlikWebConnectors\Data\[CONNECTOR_NAME]\Cache

Locate the Data folder in Windows Explorer, and do the following:

  1. Right click on the Data folder and select Properties from the drop-down menu.
  2. Click the Advanced button.
  3. In the Advanced Attributes dialog check the Compress contents to save disk space option. Click OK.
  4. Confirm the attribute change by selectiing the Apply changes to this folder, subfolders and files radio button. Click OK.
  5. Check that the Data folder is now highlighted in blue text to indicate that it is compressed.

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – let us know how we can improve!