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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Expression Syntax

My data contains two columns: Amount and Category. The category column has three options: B, C, and O. I would like to add an expression that would only look at the sum for category "B" or "O" or both "B+O". I am looking for some help with the syntax

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Maybe

sum(if(Category = 'B' or Category = 'O', Amount))

resp.

sum({<Category = {'B','O'}>} Amount)

View solution in original post

1 Reply
swuehl
MVP
MVP

Maybe

sum(if(Category = 'B' or Category = 'O', Amount))

resp.

sum({<Category = {'B','O'}>} Amount)