# New to QlikView

Discussion board where members can get started with QlikView.

Announcements
QlikWorld 2020: Join us May 11 - 14, 2020 in Phoenix, AZ. Register early and save \$400. Learn More
Partner

## Pivot Table Dimensionality()2 Total Used As Denominator for Dimensionality ()3 Expression

Hello,

I'm trying to create a "precent of total" expression (see attached screen shot).  The issue is that I need to have the denominator of the expression below be the subtotal amount of the previous dimension for all of the rows in the next dimension level.  Using the Aggr function in the current expression below, I was able to show the previous dimensions subtotal but, it is only showing the subtotal on the last row of the section.

I think I'm close.  Can anyone push me over the line....?    Thank you!!

=Sum(quantity) / Aggr( Count(orderid),Store#,item_type)

1 Solution

Accepted Solutions
Highlighted
MVP

## Re: Pivot Table Dimensionality()2 Total Used As Denominator for Dimensionality ()3 Expression

Can you try one of these:

=Sum(quantity)/Count(TOTAL <Store#, item_type> orderid)

or

=Sum(quantity)/Aggr(NODISTINCT Count(orderid),Store#,item_type)

4 Replies
Highlighted
MVP

## Re: Pivot Table Dimensionality()2 Total Used As Denominator for Dimensionality ()3 Expression

Can you try one of these:

=Sum(quantity)/Count(TOTAL <Store#, item_type> orderid)

or

=Sum(quantity)/Aggr(NODISTINCT Count(orderid),Store#,item_type)

Partner

## Re: Pivot Table Dimensionality()2 Total Used As Denominator for Dimensionality ()3 Expression

You did it again Sunny!

Thank you!!

MVP

## Re: Pivot Table Dimensionality()2 Total Used As Denominator for Dimensionality ()3 Expression

Which one of the two worked? If both did, then I suggest using the 1st one since it is Aggr() free

Partner

## Re: Pivot Table Dimensionality()2 Total Used As Denominator for Dimensionality ()3 Expression

I used the first one as we all know Aggr is resource heavy.