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

Set analysis together with an if statement

Goodday,

I'm new here and this is the first time i ask a question on a forum

Can somebody help me with the next formule?

The formule is wrong

sum({$<[winkel naam]={Maasstraat}>}if(sum([transactie bedrag])>0, sum([transactiebedrag kostprijs])))

-if(sum([transactie bedrag])>0, sum([transactiebedrag kostprijs]))*1.01

this part of te fomule is working correctly

sum({$<[winkel naam]={Maasstraat}>}

this part is also working correctly

Together it is not working

Thanks in advance

the Bakermen

5 Replies
Anonymous
Not applicable
Author

Hi,

Try:

sum({$<[winkel naam]={Maasstraat},[transactie bedrag}= {'>0'} >},[transactiebedrag kostprijs]))

Not applicable
Author

Hi,

Thanks for the fast reaction.

Sorry it is not working it is red underlined from this part: [transactie

bedrag}= {'>0'} >},[transactiebedrag kostprijs]))

neetha P schreef op 24-1-2015 om 14:47:

>

>

Qlik Community

>

anbu1984
Master III
Master III

Add quotes around string 'Maasstraat' and replace } by ]


=sum({$<[winkel naam]={'Maasstraat'},[transactie bedrag]= {'>0'} >}[transactiebedrag kostprijs]))

francoiscave
Partner - Creator III
Partner - Creator III

Hi Remko,

See th document below to play with Set analysis :

Set Analysis

Document posted by Geeta Alhan

Have fun with QV,

François

Not applicable
Author

if(sum([transactie bedrag])>0, sum({$<[winkel naam] = {Maasstraat} >} [transactiebedrag kostprijs]))

Found the solution