Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I'm new to Qlik and trying to explore the tool.
I have requirement, where need to do running sum(measure) for each month. I was able to attain running sum but for every year sum get reset. Please look at the below table. Sum got resets for year 2012 and 2013
The following formula is used
rangesum(above(round(sum(if(Match(Status,'A','B') and Typ='AB',Measure1,0))),0,rowno()))
Year | Month | Measure1 |
2011 | Jan | 0 |
2011 | Feb | 0 |
2011 | Mar | 0 |
2011 | Apr | 29 |
2011 | May | 109 |
2011 | Jun | 235 |
2011 | Jul | 278 |
2011 | Aug | 490 |
2011 | Sep | 524 |
2011 | Oct | 531 |
2011 | Nov | 699 |
2011 | Dec | 810 |
2012 | Jan | 14 |
2012 | Feb | 148 |
2012 | Mar | 378 |
2012 | Apr | 479 |
2012 | May | 670 |
2012 | Jun | 1014 |
2012 | Jul | 1241 |
2012 | Aug | 1787 |
2012 | Sep | 1941 |
2012 | Oct | 2217 |
2012 | Nov | 2290 |
2012 | Dec | 2352 |
2013 | Jan | 8 |
Can anyone suggest how to attain running sum and total regardless of the month and year?
Hi, try this expression:
rangesum(above(TOTAL round(sum(if(Match(Status,'A','B') and Typ='AB',Measure1,0))),0,rowno(TOTAL)))
JV
Are you trying to do this in a pivot table where Months are pivoted??
Hi, try this expression:
rangesum(above(TOTAL round(sum(if(Match(Status,'A','B') and Typ='AB',Measure1,0))),0,rowno(TOTAL)))
JV
Yes, I was using Pivot table
Many thanks Juan, It worked perfectly.