Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Need help with set analysis expression

Dear all,

I really need help with this expresion. I have attached an example qvw. What I need to do is to show the colors of the first series for each product. First series is th eminimum series and can change depending on the selection (for example if you select special colors).

I tried to use set anylsis for that

concat( distinct {< Product_series ={$(=min(Product_series))}> } Product_color, ', ')

but it gives me correct values only if one product is selected. If I do not select a product it searches for the minumum of product series and doesn't pay attention to my dimension (product id). I need it to work for each product id though..

As you see in the screenshot below I dont get light blue color for my first series of the 4087 product. Thats because my set expression looks for series 1.

lb.jpg

As soon as I filter for one product 4087, I get the correct value, beacues my set expresion gives me 4 as the minimum series.

lbc.jpg

I think I am missing something in the expression but can't find the solution.

Does anyone have an idea how to make it work? I would really appreciate your help.

Best regards,

Marina

1 Solution

Accepted Solutions
sunny_talwar

Set analysis is evaluated once per chart, try using Aggr() function here:

Concat(Aggr(If(Product_series = Min(TOTAL <Product_id> Product_series), Product_color), Product_id, Product_series, Product_color), ', ')

View solution in original post

2 Replies
sunny_talwar

Set analysis is evaluated once per chart, try using Aggr() function here:

Concat(Aggr(If(Product_series = Min(TOTAL <Product_id> Product_series), Product_color), Product_id, Product_series, Product_color), ', ')

Not applicable
Author

Exactly what I needed, thank you so much!