Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

12-month accumulation / How to?

error loading image

I have found some examples like YTD, therefore none of 12-month accumulation.

Per example, in filed Jun 2008 the sum would be "Jun08+May08+Apr08+Mar08+Feb08+Jan08+Dec07+Nov07+Oct07+Sep07+Aug07+Jul07".

Thank you!

4 Replies
Not applicable
Author

aletrindad -

You can create your rolling 12 month accumulation by using this formula


sum(if(inyear(MonthYear, $(vPeriod), 0, month(addmonths($(vPeriod), -11))), Failures))


In the code above you will need to set the vPeriod variable [Settings > Variable Overview > Add]

Hope this helps.

Tyson

Not applicable
Author

Hi Tyson,

was it the value vPeriod in Vaiablelist ?

do you have any QVD exampel for that?

Thanks.

Not applicable
Author

Hi Tyson!

I didn't understand the Variable vPeriod and also the relation between MonthYear and the Variable into inyear function.

I would be very gratefull, if you share with us, into the QVD file attached.

Thanks again! Yes

Not applicable
Author

Hi,

see also this example (Set Analysis).

Good luck!

Rainer