Skip to main content
Announcements
Qlik Connect 2025: 3 days of full immersion in data, analytics, and AI. May 13-15 | Orlando, FL: Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
veeranj
Creator II
Creator II

Calculating the rolling 12 months sum and displaying it from the middle of the months

Hi All,

i have the data as below

SS,Attrmnth,Monthdisengagemens

SS1,JULY 2013,10

SS2,AUG 2013

Header 1Header 2Header 3
SSMONTHDISENGAGEMENTS
SS1JULY 201410
SS1AUG 20149
SS1SEP 20142
SS1OCT 20145
SS1NOV 20146
SS1DEC 20142
SS1JAN 20141
SS1FEB 20142
SS1MAR 20142
SS11APRIL 20141
SS1MAY 20142

I have to show in the pivot table the past cumulative 12 months sum of disengagemnets where months are transposed.
For EX: For july it is same as 10.

For Aug,it should be sum of Aug and  July(10+9).

this is am able to get using the below  expression if i display the data from July 2014

rangesum(BEFORE ( sum( MnthlyDisEngCount),0,12)).

Here the record is starting from July 2014 so we have no problem in writing the above expression.

But the requirement is i want to show this data only from the Year 2014 only.
When i am filtering this data for the month of year=2014 in the dimension itself,i am not getting the desired result.
But from the month of Jan 2014,it should give the summation of past 12 months data .
Can any one help me on this.

Thanks,

Anjee

3 Replies
segador_
Partner - Contributor III
Partner - Contributor III

Hi

You need to add second calendar

Like this

http://community.qlik.com/message/733201#733201

Regards, Igor.
veeranj
Creator II
Creator II
Author

Hi,

That we can achive using AS of tables.

but  do we have an option of doing it using rangesum functions.

Thanks,

Anjee

segador_
Partner - Contributor III
Partner - Contributor III

Unfortunately RangeSum does not work with Set analysis... And after any selection of calendar formula using RangeSum will not work as you need.

Regards, Igor.