Qlik App Reload Telemetry II
This is a follow on from the last Qlik post on basic reload statistics. If you want deeper analysis you can use the following Qlik script to capture one or more specific table reloads in an app.
For each table you want to assess, there is a starting and ending block of code. The starting block goes before the usual script and the the end block, logically, goes after the load script.
The end results is a table called MetaData that for each configured instance, provides a summary of how long it took to load the data as well as some information on row and field numbers.
If you want to make this even more comprehensive you can write the results out to a QVD or similar to create a time series.
/* Capture data load metadata i.e. see how long it takes for a table to import */ // Variables Set vTable = '<My Table>'; Let sStartTime = Now(); // The start block finishes here // Dynamically name table and have ususal code here [$(vTable)]: Load //<rest of table load script here> ; // Record metadata (this is the end block) [MetaData]: Load '$(vTable)' As [Table Name], NoOfRows ( '$(vTable)' ) As [No of Rows], NoOfFields ( '$(vTable)' ) As [No of Fields], '$(vStartTime)' As [Start Time], Now() As [Completed Time], Interval(Now() - Date('$(vStartTime)'), 'hh:mm:ss') As Duration AutoGenerate 1 ; // Clean up by removing data table Drop Table [$(vTable)];