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: 
kkarlste
Creator
Creator

clause problem

Hi

Idon't understand what is this clause problem.

It's working if I comment's second if clause out.

And if I comment's first clause out then second clause working
Where is cutoff or comma first and second if clause between

=if(Match(TyönjohtajaNro,'009225','009153','009161','009122','009104') AND Match(Tuottovarattavat,'Kyllä'),Sum(Kulut/0.9),sum (Veroton)
If(Match(Tuottovarattavat ,'Kyllä'),Sum(Kulut/0.85), sum (Veroton)))

2 Replies
swuehl
MVP
MVP

Not sure I understand.

Your expressions is

=if(Match(TyönjohtajaNro,'009225','009153','009161','009122','009104') AND Match(Tuottovarattavat,'Kyllä')

// if condition

,Sum(Kulut/0.9) // then branch

,sum (Veroton) If(Match(Tuottovarattavat ,'Kyllä'),Sum(Kulut/0.85), sum (Veroton)) // else branch

)

Your else branch seems not be valid. What do you want to achieve here?

Or
MVP
MVP

Your If() ends after the first instance of Sum(Vereton) - you've provided a condition, a THEN, and an ELSE. It just needs to be closed.

If you're trying to nest if() statements, you need to remove the first Sum(Veroton) and use the ELSE area for your second if().