Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Sum Only Expression Help!

Hi gang, i need your help. I need to sum only regional contracts. I have a listing of contracts, and some of them are tagged as "regional." How can i sum only regional contracts using an expression?

VendorValueContract Type
Ricks' Car$10Regional
Jim Auto$55Regional
J&J taxi$5Local

the answer would be $65 (Ricks and Jims total)

Regards,

Brian

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Brian, you could use a sum(if()) for this

=sum( if([Contract Type] = 'Regional', Value))

or equivalent, but better performing a set expression

=sum( {<[Contract Type]={Regional}>} Value)

Just put this expression in a chart object, e.g. a text box.

Hope this helps,

Stefan

View solution in original post

1 Reply
swuehl
MVP
MVP

Brian, you could use a sum(if()) for this

=sum( if([Contract Type] = 'Regional', Value))

or equivalent, but better performing a set expression

=sum( {<[Contract Type]={Regional}>} Value)

Just put this expression in a chart object, e.g. a text box.

Hope this helps,

Stefan