Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
UserID2626
Partner - Creator III
Partner - Creator III

Alternate state in Calculation condition section qlik sense

Hi,

Is it possible to apply alternate condition in calculation condition, i tried with expression its not working

GetSelectedCount(Only({[A]}Product_ID))=1 //getting error *Nested aggregation not allowed*

GetSelectedCount(aggr(only({[A]}Product_ID),Product_ID))=1 //No error but not working correctly

How to apply alternate state ??

 

Labels (3)
1 Solution

Accepted Solutions
UserID2626
Partner - Creator III
Partner - Creator III
Author

Thank you so much  

I  got solution from Your post, but the expression you mentioned was not worked. Below expression is working correctly.

GetSelectedCount([Product_ID],True(),'A')=1

https://help.qlik.com/en-US/sense/September2019/Subsystems/Hub/Content/Sense_Hub/ChartFunctions/Fiel...

So Marking this as a solution.

Thanks   &    

View solution in original post

5 Replies
DavidM
Partner - Creator II
Partner - Creator II

IF A is name of your alternate state, try this:

 

GetSelectedCount(Only({<Product_ID=[A]::Product_ID>}Product_ID))=1

UserID2626
Partner - Creator III
Partner - Creator III
Author

Thanks for the response  

But I am getting the same error which mentioned in question 

DavidM
Partner - Creator II
Partner - Creator II

Remove only from that formula

tresesco
MVP
MVP

In Getselectedcount() you can directly use alternate state, it was long back (in some qv 11.xx) when it was not allowed. 

Capture.PNG

 

So try like:

GetSelectedCount({[A]} Product_ID)=1

UserID2626
Partner - Creator III
Partner - Creator III
Author

Thank you so much  

I  got solution from Your post, but the expression you mentioned was not worked. Below expression is working correctly.

GetSelectedCount([Product_ID],True(),'A')=1

https://help.qlik.com/en-US/sense/September2019/Subsystems/Hub/Content/Sense_Hub/ChartFunctions/Fiel...

So Marking this as a solution.

Thanks   &