Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
zagzebski
Creator
Creator

If statement within set analysis

I am trying to find the most efficient way to address two flags that we use... (1) a flag that is for Year to Date amount and (2) a flag that is for the last 12 months.

I want to incorporate the best way to address the flags (above) when a user clicks the "YTD" button or the "TMT" (twelve months trailing) button.

So what is the most efficient way to choose one of these expressions based on the YTD or TMT selection. Is there way to have an If statment WITHIN the set analysis of one expression?

I have about 75 charts I have to address this with so looking for the most efficient way!  The stripped down version of the expressions I need based on user selection:

sum({<YTD={'1'}>}Amount)

and

sum({<TMT={'1'}>}Amount)

THanks in advance

11 Replies
Anonymous
Not applicable

in my case there is YTD or TMT selected, if in your case neither of them needs to be selected, so what calendar should be used? you must provide a third scenario for that

zagzebski
Creator
Creator
Author

Thanks! I am going to run with this.