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: 
PrashantRupani
Creator
Creator

OR condition in Set modifier

I have this set analysis expression : sum({1 <Year={1997},[Customer City] = {'London'}>} Sales)

I understand this will pull the sum of sales of year 19997 AND London. 

How to modify this expression if the condition is to show sum of sales for 1997 OR London?

Labels (1)
2 Solutions

Accepted Solutions
Nicole-Smith

You can use + between sets to create an OR condition:
sum({1 <Year={1997}>+<[Customer City] = {'London'}>} Sales)

View solution in original post

MayilVahanan

Hi @PrashantRupani 

Yes, its will give both. 

Its like "OR" Conditon.

 

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.

View solution in original post

4 Replies
Nicole-Smith

You can use + between sets to create an OR condition:
sum({1 <Year={1997}>+<[Customer City] = {'London'}>} Sales)

PrashantRupani
Creator
Creator
Author

Ok I see what you saying.

 + is an UNION Operator. So that will give results of 1997 or London depending on the data available in the database.  If there is data available for both, then it will give both. Correct? Can you confirm my understanding?

MayilVahanan

Hi @PrashantRupani 

Yes, its will give both. 

Its like "OR" Conditon.

 

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
PrashantRupani
Creator
Creator
Author

Thanks Mayil.