Qlik Community

Ask a Question

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
March 11, 2PM EST: Do More with Qlik - Getting Started wtih Qlik Sense SaaS - Redux. REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Reuven12
Contributor
Contributor

Variable equal to parameter inside of set analsys

Hey, 

I have an issue with variables that use as a flag inside of set analsys.

My variable called 6_Month_Flag:

IF(MonthStart([Calendar date])= AddMonths( MonthStart($(Close_Date_Default)),-6) ,'Y','N')

But when im trying to use it inside of set analsys it just dont work

sum({$<(6_Month_Gap)={'Y'}>}Amount)

I tried so many way but none of them is working. 
What is the problem and how can i fix it?

Labels (1)
2 Replies
QFabian
Specialist
Specialist

Hi @Reuven12 , you have to use fields, not variables in that part of the set analysis.

So you can  create a field using the variable expresion, and then use it

You expression should look like this :

sum( {$< 6_Month_GapFIELD  = {'Y'} >} Amount)

QFabian
Reuven12
Contributor
Contributor

Hey @QFabian ,

I  can't use a field because  the date change by user selection.

Thank you, Maayan.