Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
Nin_04
Contributor II
Contributor II

Summing nine months before each month

Hello everyone,

I need to create a trend line with  dimension [Year Month]  interval YTD (jan to current month) and for each month i have to calculate the nine month before. I have already created thi graph with this measure:

Rangesum(above(count(Transaction),9)) and the formula works correctly if I don't apply any filter. The problem is that my dimension have to be a YTD so from January to current month but with this formulas January not include the nine month before.

 

How can i do?

Thanks a lot!

Labels (1)
1 Reply
F_B
Creator III
Creator III

Hi @Nin_04 ,

here's a suggestion for how you might modify your expression to achieve the desired result:

Rangesum(Above(Count({<[Year Month]={">=$(=Date(AddMonths(MonthStart(Max([Year Month])),-8),'YYYY-MM'))<=$(=Max([Year Month]))"}>} Transaction), 9))

I would like to point out that I didn't test if it works, but I hope it can be helpful