Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
subramanir3
Contributor
Contributor

Error: Nested Aggregation is now Allowed.

Expectation: Find the average of “Total Sales” and then find how many salespeople have an average order value of less than the overall average sales in each country. Use Dimensions as Country. Use Straight Table

 

The formula being used: 

Sum(
if(
aggr(avg(LineSalesAmount), [Customer Country], [Sales Person])
<
avg(LineSalesAmount)
,1,0))

 

However, I am getting this error "Error: Nested Aggregation is now Allowed." Please guide me to the solution.

1 Reply
trdandamudi
Master II
Master II

Can you give a try on the below expression and see if it works:

Sum(
if(
avg(aggr(LineSalesAmount, [Customer Country], [Sales Person]))
<
avg(LineSalesAmount)
,1,0))