Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
QlikWorld 2020: Join us May 11 - 14, 2020 in Phoenix, AZ. Register early and save $400. Learn More
Highlighted
vijitbhargav
New Contributor III

Problem in deriving Aggregated sum based on a Field

Hi. Good Afternoon.

Before going forward with the problem, please refer to the situation where I am representing the following data in a Pivot table:

WarehousePlantOccupancy in %
K01A016
F013

Occupancy in % = sum([Bin Occupancy]) of Plant / SUM([Bin Occupancy]) of 'Warehouse'  * 100

** where [Bin Occupancy] is a calculated value

I am unable to get the Aggregated sum based on the 'Warehouse' with the below expression. Tried several ways but the problem persists.

=sum([Bin Occupancy]) / aggr(([Bin Occupancy]), Warehouse)  * 100

Please assist.

Thank You.

Regards,

Vijit

Tags (2)
1 Solution

Accepted Solutions
vijitbhargav
New Contributor III

Re: Problem in deriving Aggregated sum based on a Field

Hi.

Even after using dimentionality() function, I found a simple solution:

= Sum([Bin Occupancy])/Sum(Total <[Warehouse]> [Bin Occupancy])

Regards,

Vijit

View solution in original post

4 Replies
Not applicable

Re: Problem in deriving Aggregated sum based on a Field

Hi,

try like this.

   (aggr(sum([Bin Occupancy]),Plant) / aggr(sum([Bin Occupancy]), Warehouse) ) * 100

if this will not helpful for your then please attach sample file here.

Thanks,

Ashutosh

Not applicable

Re: Problem in deriving Aggregated sum based on a Field

Hi Vijit,

   

Did you gave a try using Total as below?

Occupancy in % = sum([Bin Occupancy]) of Plant / SUM(Total [Bin Occupancy]) of 'Warehouse'  * 100

=sum([Bin Occupancy]) / aggr(Total ([Bin Occupancy]), Warehouse)  * 100

Regards,

NR

vijitbhargav
New Contributor III

Re: Problem in deriving Aggregated sum based on a Field

Hi.

Either case, it's not functioning. Please also make a note that Warehouse has two values = 'K01' and 'B01'

Regards,

Vijit

vijitbhargav
New Contributor III

Re: Problem in deriving Aggregated sum based on a Field

Hi.

Even after using dimentionality() function, I found a simple solution:

= Sum([Bin Occupancy])/Sum(Total <[Warehouse]> [Bin Occupancy])

Regards,

Vijit

View solution in original post