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: 
aarohipatel
Creator II
Creator II

Set analysis with Aggr

Hello,

I am trying to implement an existing aggr expression with set analysis.

Sum(Aggr(If(Sum(ABC_field)=0,0,1),XYZ_field))

in this expression, I would like to add one more condition: Year= $(Year)

I have a variable for year.

Could you please advise on how to achieve these two in one set expression.

 

Thanks in advance

 

1 Solution

Accepted Solutions
rubenmarin

Hi, can you try this?:

Sum({<Year={$(Year)}>} Aggr(If(Sum({<Year={$(Year)}>} ABC_field)=0,0,1),XYZ_field))

View solution in original post

1 Reply
rubenmarin

Hi, can you try this?:

Sum({<Year={$(Year)}>} Aggr(If(Sum({<Year={$(Year)}>} ABC_field)=0,0,1),XYZ_field))