Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

XOR Function

Hi All,

Could someone help me with this.

I have table as below. But i want to see rows to user who belong to any one AREA but not both or NULL

OutPut: B and C.

Sample.png

Thanks in advance

1 Solution

Accepted Solutions
tresesco
MVP
MVP

And with increasing number of Areas, you might want to make it dynamic like:

=sum({<User*={"=count({1} DISTINCT Area)<$(=count(Distinct Area))"}>} [X Sales]+[Y Sales])

View solution in original post

4 Replies
Anil_Babu_Samineni

XOR we can use like If condition -- If(XSales >= 20 or YSales <=30, 'True','False')



Can you share sample data and expected output which demonstrates the output

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
PrashantSangle

Hi,

use "\" for XOR

For details read below thread

Implicit Set Operators

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 🙂
Peter_Cammaert
Partner - Champion III
Partner - Champion III

You can accomplish this by using set analysis and an expression search.

Your original post may not be the most detailed (your table looks like an aggregated end-result instead of a base table from which to start), but you can try with a straight table that includes dimensions User & Area, and an expression like:

=sum({<User*={"=count({1} DISTINCT Area)=1"}>} [X Sales]+[Y Sales])

See also the example in attachment

Best,

Peter

tresesco
MVP
MVP

And with increasing number of Areas, you might want to make it dynamic like:

=sum({<User*={"=count({1} DISTINCT Area)<$(=count(Distinct Area))"}>} [X Sales]+[Y Sales])