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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
ronaldwang
Creator III
Creator III

syntax on alternate state to exclude some value

I have a field named activity and the distinct value in the field is null, 1, 2, 3 and I have assigned a list box of this filed as alternate state “Activity”.

If in the expression I want to calculate the sum of amount but putting a filter on activity where the field value will not equal to 2 (or in other words, should including null, 1, 3). What is the best syntax I should be using? thanks

1 Solution

Accepted Solutions
Anil_Babu_Samineni

Create one Alternate State let's assume AS01. Then Try this?

Count({AS01<Activity -= {2}>} DISTINCT Value)

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

View solution in original post

2 Replies
Anil_Babu_Samineni

Create one Alternate State let's assume AS01. Then Try this?

Count({AS01<Activity -= {2}>} DISTINCT Value)

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
qlik4asif
Creator III
Creator III

What is the use of alternate state here

Any how Count({<Activity -= {2}>} DISTINCT Value)  will exclude activity 2.