Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Group within aggregate?

This may be a very basic question, but I'm pretty new to QlikView and have not been able to find my answer by searching thus far.  I'm using v11.

I have a straight table chart where I need to show an quarterly average of a monthly count.  I already have 2 dimensions segmenting the data by categories - one into rows and the other into columns.  I'm limiting the data to current quarter in the expression and getting a distinct count there, but that gets a count of distinct units across the quarter, rather than an average of the 3 months' distinct counts. I added another column dimension for the months under the dimension that creates the column categories, but the subtotal at the category level is still pulling distinct for the whole quarter instead of the monthly average.  I thought I could use the settings in the 'Total Mode' box on the Expressions tab, but they are grayed out.

Any ideas?  Again, I'm new at this, so as much detail as you can give me is appreciated.  Thanks!

1 Reply
Gysbert_Wassenaar

If you want an average of counts in a pivot table then you need to wrap the inner count in the avg with the help of the aggr function: avg(aggr(count(units), Dim1, Dim2, ... , DimN)). Replace Dim1, Dim2, ... , DimN with the dimensions of your pivot table.


talk is cheap, supply exceeds demand