Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
ercmntkkl
Contributor
Contributor

Dynamic date range in set analysis

Hello everyone,

I have 2 variable one of is vFirstMonth keeps constant value of 01. And the other ona is vSelectedMonth which data comes from variable input drop down options. 

Lets say i choose 03 for vSelectedMonth from dropdown list.

I would like to calculate total sales between these months range[01,03]. I wrote the formula below, search in blog and tried them also but, couldn't work it correctly.

sum({<[TakvimAyı]={">=$(=vFirstMonth) <=$(=vSelectedMonth)"}>}[TotalSales per Employee])

Where am i doing wrong?

thanks in advance.

2 Replies
vmoreno2605
Creator
Creator

Is your value really '01'? or is it '1', because if the answer is '01' it wouldnt work since qlik thinks it's a string. 

 

And if you have a constant value of 01 why do you need it? 

ercmntkkl
Contributor
Contributor
Author

Hello,

When I try sum({<[TakvimAyı]={">$(=vSecilenAy)"}>}[Cost per Emplooye MTD]) or  sum({<[TakvimAyı]={"$(=vilkay)"}>}[Cost per Emplooye MTD]) it gives correct value. Value of constant variable and dynamic variable 01 work fine.

If any other idea to give range filter can you share with me?