Skip to main content
Announcements
Qlik Connect 2025: 3 days of full immersion in data, analytics, and AI. May 13-15 | Orlando, FL: Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
srik00001
Contributor III
Contributor III

Variable in Set analysis condition

I am trying to pass a variable in the set analysis statement as below to calculate a customers in a range in product B and display only those customers in product A. I get an error with the below calculation. I have also attached the QVW !

='(' &chr(34) &

    concat({$<Product={'Chains'},Customer = P({$<$(v_value)={"<=$(=$(v_max)*$(v_factor))  >=$(=$(v_min)*$(v_factor))"}>} Customer)>}

            DISTINCT Customer, chr(34)&'|'&chr(34))

&chr(34)&')'

4 Replies
alexandros17
Partner - Champion III
Partner - Champion III

I think that the left side of a condition in set analysis cannot contain a variable....

swuehl
MVP
MVP

Well, it can, but only if  the dollar sign expansion expands it to a field name.

swuehl
MVP
MVP

Not really sure what you are trying to achieve, so I changed quite a lot. See attached.

srik00001
Contributor III
Contributor III
Author

The user will select a range and qlikview needs to limit the customers to Product= Chains within that range.

The list of customers will then be applied to all other objects.

Thanks for your help in pointing me in the right direction