I have a table that contains several transactions on each combination month+project and I want to create a line chart in Qlik Sense with Dim: Month.
So, problems:
1. Each month in the diagram should show the total amount for the month but only include projects where the total amount for the period is >0. Projects where total amount for the period <0 should not be included in the diagram.
2. I want the values to be accumulated (add the values for each month).
I have tried like this for problem 1. But, you can't put the if-statement outside because then I will get the wrong result:
If(
Sum(
aggr(
Sum({<Year = {$(#=max(Year))}, Month= } >} Price)
,Month, Project))
> 0,
Sum(
aggr(
Sum({<Year = {$(#=max(Year))}, Month= >} Price)
,Month, Project))
, null() )