Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Not applicable

set analysis and filters

sum({$<Year={2000}”}>} Sales)

Returns the sales for current selection, but with new selection year=2000.  if someone applies a filter year=2001, the above set analysis still returns sum of sales for year 2000.  How do i modify this so that if a user applies no year filter it return sum of sales for year 2000, but if a user applies a filter year other then 2000, then the function returns 0?

Tags (1)
1 Solution

Accepted Solutions

Re: set analysis and filters

sum({$<Year*={2000}>} Sales). The * means intersect the user selection with the value 2000. So if the user selections something else than 2000 the intersection will be empty and the expression returns 0.


talk is cheap, supply exceeds demand
3 Replies

Re: set analysis and filters

sum({$<Year*={2000}>} Sales). The * means intersect the user selection with the value 2000. So if the user selections something else than 2000 the intersection will be empty and the expression returns 0.


talk is cheap, supply exceeds demand
MVP
MVP

Re: set analysis and filters

Use the intersection operator *

sum({$<Year *= {2000}”}>} Sales)

Not applicable

Re: set analysis and filters

Wow, that's easy.  Thanks Gysbert