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: 
Ericus
Contributor II
Contributor II

Conditional aggragate function

I'm still learning Qlik and this is probably fairly easy, but I haven't managed to figure it out. I have created a pivot table for an app which groups all invoice posts to showcase all costs invoiced to a customer. But they also want to know how much they have consumed. Consumption is the number data from a specific set of products so I was wondering how I might write a function that can conditionally summarize only a sertain set of values like the SUMIF function from excel. Can I combine the Sum and the IF function in some way to do this?

Labels (1)
1 Solution

Accepted Solutions
chris_djih
Creator III
Creator III

you could easily use something like this:  If( x<y, sum(z)) in your epression.
But there is a far better way in Qlik, named Set-Analysis. Please have some looks into this and try to use this instead of If-statements. Since If-Statements decreases your performance (in Measures).

grafik.png
further readings: https://www.analyticsvidhya.com/blog/2014/01/set-analysis-qlikview/

If you found help, mark the correct answer and give some likes to ALL contributors, that tried to help.

View solution in original post

1 Reply
chris_djih
Creator III
Creator III

you could easily use something like this:  If( x<y, sum(z)) in your epression.
But there is a far better way in Qlik, named Set-Analysis. Please have some looks into this and try to use this instead of If-statements. Since If-Statements decreases your performance (in Measures).

grafik.png
further readings: https://www.analyticsvidhya.com/blog/2014/01/set-analysis-qlikview/

If you found help, mark the correct answer and give some likes to ALL contributors, that tried to help.