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: 
Not applicable

sum ( if )

Hi

Is there any other calculation for the following expression.

Sum (if (column=' name', if (column=' name', other column)calculation column)).

Thank you.

16 Replies
shree909
Partner - Specialist II
Partner - Specialist II

Hello

WHy dont  you use the set analysis. and match function to get the desired results.

or else post a sample file with the data.

Thanks

sree

Not applicable
Author


Hi Sree,

Thanks for the reply. And expressions are below.

sum(if(SCENARIO='S1' or SCENARIO = 'JUMP-OFF'  ,RWA))
sum(if(SCENARIO='S2' or SCENARIO = 'JUMP-OFF'  ,RWA))
sum(if(SCENARIO='S3' or SCENARIO = 'JUMP-OFF'  ,RWA))
sum(if(SCENARIO='S4' or SCENARIO = 'JUMP-OFF'  ,RWA))
sum(if(SCENARIO='S5' or SCENARIO = 'JUMP-OFF'  ,RWA))
sum(if(SCENARIO='S6' or SCENARIO = 'JUMP-OFF'  ,RWA))

6 expressions have been used in chart. Is there any replacement for the above with qlikview functions.

Thank you,

its_anandrjs
Champion III
Champion III

You can try with

sum({<SCENARIO= {'S1'}, SCENARIO= {'JUMP-OFF'}>}  RWA)

sum({<SCENARIO= {'S2'}, SCENARIO= {'JUMP-OFF'}>}  RWA)

sum({<SCENARIO= {'S3'}, SCENARIO= {'JUMP-OFF'}>}  RWA)

sum({<SCENARIO= {'S4'}, SCENARIO= {'JUMP-OFF'}>}  RWA)

sum({<SCENARIO= {'S5'}, SCENARIO= {'JUMP-OFF'}>}  RWA)

sum({<SCENARIO= {'S6'}, SCENARIO= {'JUMP-OFF'}>}  RWA)

Or

Sum({<SCENARIO= { 'S1','S2','S3','S4','S5','S6'  }, SCENARIO= {'JUMP-OFF'}>}  RWA)

Provide any sample then it will more clear.

Regards

Anand

Not applicable
Author

Hi Anand,,

Only Jump off data, I can see even if I select S1.

Thank you,

its_anandrjs
Champion III
Champion III

Please explain with an example output or input as any inline table with few data.

Regards

Anand

Not applicable
Author

1.PNG2.png3.png

Not applicable
Author

output should come as per the above screen shots but when I applied the given formula then out put is coming like:4.png

SunilChauhan
Champion II
Champion II

sum(if((SCENARIO='S1' and SCENARIO='S2' and SCENARIO='S3'  and SCENARIO='S4' and SCENARIO='S5')or SCENARIO = 'JUMP-OFF'  ,RWA))

Sunil Chauhan
its_anandrjs
Champion III
Champion III

Then try with this

Sum( If( Match( SCENARIO, 'S1','S2','S3','S4','S5','S6' ) And SCENARIO = 'JUMP-OFF'   RWA ))

Regards

Anand