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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

set analysis expression

am encountering an error in the below set analysis expression :

count({$<$(vstate)={'x'}>}field) / count({$}field)

the error shown in red curly brackets,

can anyone please help and guide for the above

Labels (1)
8 Replies
Anil_Babu_Samineni
MVP
MVP

What was the variable you declare?

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Anonymous
Not applicable
Author

i didnt get your question,

do u want to ask which variable

x is a variable

Anil_Babu_Samineni
MVP
MVP

That is bug, But if you hit Ok i think condition should work

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Nagaraju_KCS
Specialist III
Specialist III

You have declared variable name. vstate

what you have declared in definition ?

mangalsk
Creator III
Creator III

is x is value or is it variable, sometimes it shows as red but works.. if x is also a variable then use =$(x) instead of only x

effinty2112
Master
Master

Hi,

Try : count({$<$(=vstate)={'x'}>}field) / count({$}field)

Good luck

Andrew

Kushal_Chawda
MVP
MVP

This shows error, but actually it works. Try testing it

pathiqvd
Creator III
Creator III

Hi,

   May be try like this ,

count({$<statefieldname={"$(varibalename)"}>}field) / count({$}field)



Regards,