Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Running Sum and Total regardless of the year/month

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()))

YearMonthMeasure1
2011Jan0
2011Feb0
2011Mar0
2011Apr29
2011May109
2011Jun235
2011Jul278
2011Aug490
2011Sep524
2011Oct531
2011Nov699
2011Dec810
2012Jan14
2012Feb148
2012Mar378
2012Apr479
2012May670
2012Jun1014
2012Jul1241
2012Aug1787
2012Sep1941
2012Oct2217
2012Nov2290
2012Dec2352
2013Jan8

Can anyone suggest how to attain running sum and total regardless of the month and year?

1 Solution

Accepted Solutions
jvitantonio
Luminary Alumni
Luminary Alumni

Hi, try this expression:

rangesum(above(TOTAL round(sum(if(Match(Status,'A','B') and Typ='AB',Measure1,0))),0,rowno(TOTAL)))


JV

View solution in original post

4 Replies
sunny_talwar

Are you trying to do this in a pivot table where Months are pivoted??

jvitantonio
Luminary Alumni
Luminary Alumni

Hi, try this expression:

rangesum(above(TOTAL round(sum(if(Match(Status,'A','B') and Typ='AB',Measure1,0))),0,rowno(TOTAL)))


JV

Not applicable
Author

Yes, I was using Pivot table

Not applicable
Author

Many thanks Juan, It worked perfectly.