Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to do rolling 12 months sum

Good morning, I'm a qlik sense beginner. I would like to know how to do rolling last 12months sum, by selecting a month / year. Thank you.

1 Solution

Accepted Solutions
Not applicable
Author

I found a way to do it.

Sum({$< [udolar_fecha_emision.autoCalendar.YearMonth]={'>=$(=Monthstart(Addmonths(Max(udolar_fecha_emision),-11)))<=$(=Max(udolar_fecha_emision))'} >}udolar_subtotal_descuento)

What do you think about it?

View solution in original post

15 Replies
Not applicable
Author

does it works the same for qlik sense?

Because it seems like qlikview.

sunny_talwar

Most of the things should work except for the option to accumulate using the accumulate check box on expression tab which is only available in QlikView

Not applicable
Author

ok i am gonna try it and let you know. thanks

Not applicable
Author

Where do I put the year in the expression?      rangesum(above(sum(Amount),0,3))

Example: if I select november- 2016


I want the sum rolling last 12 months (from december 2015 to november 2016)




Not applicable
Author

In a chart you can use the rangesum function to get the rolling sum.

rangesum(above(sum(Sales),0,12))

sunny_talwar

May be like this:

Dimension

MonthYear

Expression

Rangesum(Above(Sum({<MonthYear>}Amount),0,12)) * Avg(1)

Not applicable
Author

I have a question. Is there a chance to sum lateral instead of above? from right to left?

sunny_talwar

In a pivot table? You can use Before/After

Missing Manual - Before() and After()