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

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
danielact
Partner - Creator III
Partner - Creator III

Reference a dimension value in set analysis

I want to pull specific ranks from an aggregation of values. Currently, I'm using this expression:

sum({$<IDKey={"=aggr(nodistinct rank(Sum(Losses),4,1),Year)=1"}>}Our_Loss)

5 times, with different equals values (let's say =1, =2, =3, =4, and =5).

If I set a dimension with values 1, 2, 3, 4, 5, is there a way to reference the dimension in the expression? I created a new table with the values, called NumList, and tried this:

sum({$<IDKey={"=aggr(nodistinct rank(Sum(Losses),4,1),NumList,Year)=NumList"}>}Our_Loss)

but it didn't work.

Any ideas on how to do this?

1 Reply
vgutkovsky
Master II
Master II

This is not possible with set analysis, which is calculated once for the entire chart and does not take dimensions into accounts. To conduct a check on dimensions, you will need to use straight conditional logic (IF or PICK or something).

Regards,

Vlad