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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Adv. Indirect Set Analysis

Hi all, a lot of helpful QV doc here about set analysis but I still have one qst remained unanswered. Sorry if I'm missing some useful post.

This is QV demo example:

sum({$<CompanyName = p({$<CategoryName={'Baby Clothes'}>} CompanyName) - p({$<CategoryName={'SportsWear'}>} CompanyName)>} Sales)

Explanation: Sales for Customers who purchased Baby Clothes but not Sportswear.The first set p({}) returns CompanyName that purchased Baby Clothes.The second set p({}) returns CompanyName that Purchased SportsWear.The Unary Operator "-" between the two gives a list of Customers (CompanyName)that belong to the first but not the other set.

The qst are:

  1. can this -p() thing be done by e()
  2. and 2nd more important is how can I see the names of those Customers listed in straight/pivot chat and not just their sum of sales.

Or to make it more general how to get a list of Customer who didn't buy some Article or some Category?

Thank you in advance,

Milan

1 Solution

Accepted Solutions
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

  1. Yes: sum({$<CompanyName = p({$<CategoryName={'Baby Clothes'}>} CompanyName) * e({$<CategoryName={'SportsWear'}>} CompanyName)>} Sales)
  2. Add Customer as a dimension to the chart/table. You can hide the Sales expression if you don't want to see the amount.

talk is cheap, supply exceeds demand

View solution in original post

1 Reply
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

  1. Yes: sum({$<CompanyName = p({$<CategoryName={'Baby Clothes'}>} CompanyName) * e({$<CategoryName={'SportsWear'}>} CompanyName)>} Sales)
  2. Add Customer as a dimension to the chart/table. You can hide the Sales expression if you don't want to see the amount.

talk is cheap, supply exceeds demand