Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Aggr function

Hi to all,

I tried everything but I can't resolve this issue,hope someone can help me

I have this pivot table.

image.png

I'll try to explain what I want to do:

  • If I have Dato = 'HC PROCESS FLARING' in a SITE, when DATO = 'HC PROCESS FLARING' only Column "hc flaring sm3" must be populated; when DATO = 'PROCESS FLARING' only column Total Flaring sm3, as shown in Figure.
  • If site doesn't have DATO = 'HC PROCESS FLARING' in a SITE I need the same value for both columns.

I hope to do this in front end.

I think something with concat and aggrs, but I can't resolve it...any suggestions?

Thanks in advice!

A.

11 Replies
Anonymous
Not applicable
Author

That's not the behavior in the yellow part of you first image. Anyway, all you need is to change the second expression to

HC Flaring [Sm3]: If(Index(Concat(Total<SITE> DATO, '|'), 'HC PROCESS FLARING') > 0, Sum(Value), 0)

Not applicable
Author

Hi Bruno, thanks again.

Yellow part and green are different (one with HC process Flaring, other no).

Changing the second expression I have both column with the same values in every case, also in Site "F" and it's wrong.

Thanks again for your help!

Antonio