Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
cander19
Contributor II
Contributor II

Set Analysis - Filtering a dimension

I'm having trouble with a KPI using set analysis. I am showing totals by regions NA and EU:

='NA: '&num(sum({$<Region={'North America'}>}[Positions Remaining]),'#,##0')&' EU: '& sum({$<Region={'Europe'}>}[Positions Remaining])

It works and changes accordingly based on various filters selected. But, if I filter on a Region, it does not change. For example, with no filters selected, I get, 'NA: 140 EU: 80'. If I select any filter, I get, say 'NA: 75 EU: 20'. But, if I select a region (e.g. NA), it still shows 'NA:75 EU:20' when I want it to show 'NA:75 EU:0' since only the NA should show up. 

Labels (1)
1 Solution

Accepted Solutions
agigliotti
Partner - Champion
Partner - Champion

Hi @cander19 ,

I guess it works as expected.

Let's try this expression:

='NA: '&num(sum({$<Region*={'North America'}>}[Positions Remaining]),'#,##0')&' EU: '& sum({$<Region*={'Europe'}>}[Positions Remaining])

I hope it can help.

Best Regards

View solution in original post

3 Replies
agigliotti
Partner - Champion
Partner - Champion

Hi @cander19 ,

I guess it works as expected.

Let's try this expression:

='NA: '&num(sum({$<Region*={'North America'}>}[Positions Remaining]),'#,##0')&' EU: '& sum({$<Region*={'Europe'}>}[Positions Remaining])

I hope it can help.

Best Regards

Vegar
MVP
MVP

The solution, using an implicit set operator, provided by @cander19 should help you.

Read about implicit set operators in this Qlik Help page: Set modifiers using assignments with implicit set operators 

cander19
Contributor II
Contributor II
Author

Outstanding! Thank you very much.