Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
retko1985
Creator II
Creator II

Explain - The argument expression of one aggregation function must not contain another aggregation function.

I found this on help - Aggregation functions ‒ QlikView

Can someone give some example?

Thank you.

1 Solution

Accepted Solutions
Peter_Cammaert
Partner - Champion III
Partner - Champion III

It simply means that you cannot nest aggregation function calls (only one exception: if you put a call to Aggr() between them. Aggr() sort-of un-aggregates values)

For example, this is illegal syntax:

=Avg(Sum(SalesAmount))

whatever the dimensions in your table. But this isn't:

=Avg(Aggr(Sum(SalesAmount), Customer, Year))

Best,

Peter

View solution in original post

2 Replies
maxgro
MVP
MVP

try to read this post

Aggregations and Function Classes

Peter_Cammaert
Partner - Champion III
Partner - Champion III

It simply means that you cannot nest aggregation function calls (only one exception: if you put a call to Aggr() between them. Aggr() sort-of un-aggregates values)

For example, this is illegal syntax:

=Avg(Sum(SalesAmount))

whatever the dimensions in your table. But this isn't:

=Avg(Aggr(Sum(SalesAmount), Customer, Year))

Best,

Peter