Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Period over Period Comparison using GetFieldSelections

I am currently using flag in my calendar to calculate MTD, LastMTD, QTD, LastQTD, YTD and LastYTD.  I use these flags in my expressions and they work perfect.  What I would like be be able to do is to do the same thing, but allow the user to select a MonthYear. These values will then be need to recalculated based on the MonthYear chosen.

My expression for MTD is as follows:

Sum({1<FACTTYPE={'CHARGEOFF'}, CurMTDFlag={1}>}AMOUNT) - (Sum ({1<FACTTYPE={'RECOVERY'},CurMTDFlag={1}>}AMOUNT) + Sum ({1<FACTTYPE={'RESTITUTION'}, CurMTDFlag={1}>}AMOUNT))

I am open to all suggestions.

Thanks in advance.

Temieka

2 Replies
Not applicable
Author

setting the flags for period over period calculations wont work when you wanted these to act based on calendar selections. you will have to go with set analysis ... ex: sum({<Year ={'$(=max(Year-1))'}>}Sales)

Anonymous
Not applicable
Author

You are correct.  I know I would need to remove the flags, but I just don't know how to set up the expression.  Thanks for responding.