Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Maximize ROI with Qlik Professional Services – Expert Guidance, Faster Results: Explore Qlik Services
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to manage a progressive calculation in a Pivot table

Hi all, I'm a qlikview newbie.

I'm facing a problem that I'm trying to solve ( see the picture).

What is the best approach to reproduce in qlikview the information displayed in the picture ?

I think that I have to use a pivot table ( in a chart control).and how to manage the 'sub totals',

But I don't have a clear idea to obtain the calculation of column 'Diff'.

note : 'Diff' values are the difference of a 'Values''s item and the previous one.

'sub totals' is the sum of the values of the column 'Diff' grouped by 'Date'

on hourly base ( the first sub total is the sum of 'Diff''s values grouped by

12/04/2014  'hour' 3, the second one , is the sum grouped by 'hour 4'. etc .. )

Could you help me ?

Thanks in advance.

DateValuesDiffsub totals
12/04/2014 03:35:0012
12/04/2014 03:40:00186
12/04/2014 03:45:00191
12/04/2014 03:50:00256
12/04/2014 03:55:0029415
12/04/2014 04:00:00312
12/04/2014 04:05:00343
12/04/2014 04:10:00439
12/04/2014 04:15:00452
12/04/2014 04:20:0050521
2 Replies
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

I recommend create a date, a time and an hour field in the script. Perhaps it makes sense to calculate the Diff values in the script too. If not you can use the above() function in an expression in the pivot table. Something like sum(Values) - above(sum(Values)). If you add the hour field to the pivot table you can enable the Partial Sums option for the date dimension to get the sub totals. If you want some help with that then please post a sample document with some data.


talk is cheap, supply exceeds demand
Not applicable
Author

Thanks a lot for your answer.

I used Previous() function in the script .