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

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
prabunakil
Contributor III
Contributor III

if else qlikview expression

I want to write a if else sum qlikview expression in pivot table. Please advise. my concept is as per below:

IF [Bill Type] = {'S1'}. [KSCHL]={'Z1PR'}

     then SUM ([KONV_KWERT]*-1)

ELSE [Bill Type] = {'ZLG2'}. [KSCHL]={'Z1PR'}

     then SUM ([KONV_KWERT]*-1)


ELSE [Bill Type] = {'ZLRE'}. [KSCHL]={'Z1PR'}

     then SUM ([KONV_KWERT]*0)


Please advise the correct statement.

1 Reply
sunny_talwar
MVP
MVP

Is the last condition just 0? Sum([KONV_KWERT]*0)... Anything multiplied with 0, will be 0, right? Also, the first two conditions look the same... may be you just need this

Sum({<[Bill Type] = {'S1', 'ZLG2'}, [KSCHL]={'Z1PR'}>}[KONV_KWERT]*-1)