Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
baarathi
Creator III
Creator III

I want to compare records of the currently selected year and 2 years of its past?

I want to compare records of the currently selected year and 2 years of its past?

For example, if I currently select 1998 as the year it should compare 1996 year's subtotal with the 1998 year's subtotal, in bar chart

=sum({$<OrderYear=getfieldselections(OrderYear)-2>}Subtotal)

I'm getting the desired result, with the above statement.Can you help me the above statement and correct if it has some mistake.Thanks in advance

10 Replies
YoussefBelloum
Champion
Champion

you are welcome