Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
KennyTan
Partner - Contributor II
Partner - Contributor II

Possible to have both filter and ignored selection in a set analysis?

Hi Qlik Community,

Would like to get some insight on how to , is it possible to have both respect filter criteria and ignored criteria in a set analysis? if yes can please share with me how? 

For eg, I have below set analysis to return SUM of sales for year 2020:

 

SUM({$<year={'2020'}>}sales)

 

let said if i have a filter panel with a "product" dimension, and i would like to ignored product selection within filter panel with certain value, for eg, something as below:

 

{1<[product]={'prod1', 'prod2'}>}

 

 Is it possible to combine this 2 criteria in a set analysis? If yes can please show me how? Thanks in advance.

Basically i would like to ignored certain value in a dimension when user perform filter selection, but not to totally ignored all other available value, so something like [product]= is not viable in this case

Regards,

Kenny.

2 Replies
PrashantSangle

Yes it is possible with e()

see below link for reference

https://community.qlik.com/t5/QlikView-App-Dev/P-E-and-where-do-you-use-them/td-p/457847

 

Regards,

Prashant

Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
KennyTan
Partner - Contributor II
Partner - Contributor II
Author

Hi @PrashantSangle ,

Thanks for the replied and link provided. Try to understand the usage for E() in set analysis without any success. Can please help me understand?

I have a sample data as below (attached qvf if it can provide more clarity).

sampledata.png

Based on the explanation from the linked provided,  i can interprets below as (Please correct me if my understanding was wrong):

Get the SUM of sales for  for product on year 2019 where product color not to include red.

sum({$<product=E({1<color={'red'}>}), year={'2019'}>}sales)

I expect above set analysis will returned me something as below?

result.png

But the calculation i get is 0 with above set analysis. Not sure how this Exclude mechanism is work.

Hope you can shed some light on this please?

Thanks and Regards,

Kenny.