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

How do I make a variable value constant, irrespective of chart selection

Hi all,

I have a calculated variable in my Qliksense Desktop (3.1) app that I wish to retain a constant. But right now, the value of this variable, which I have displayed in a KPI object, keeps changing based on my chart selections.

As an example, one of the variables is calculated as below :

vCount = (Count(if([Date] = MaxDate and ([Clinical Execution Time (latest)]-[Clinical Execution Time (prev)])>0, [Dataset Name])))

Please help.

Thanks,

Kanchana

3 Replies
rubenmarin

Hi Kanchana, you can try with:

=Count({<[Date]={$(=Max({1} [Date]))}, [Dataset Name]={"=Only({1} [Clinical Execution Time (latest)]-[Clinical Execution Time (prev)])>0"}>} [Dataset Name])

I'm using set analisys instead of If() to apply the filter. And using {1} to ignore selections.

Not applicable
Author

Hi Ruben,

Thanks for your reply. But this looks complicated as I have several such calculations (even more complex ones) in my app. Would it be possible for you to show how I can convert this calculation to a set analysis expression and then use the constant setting?

Thanks,

Kanchana

kkkumar82
Specialist III
Specialist III

Hi Kanchana,

Ruben has used set analysis and made the selections constant by using {1} in the set expression. I think you have to give a try