Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
keerthanagowsi
Contributor III
Contributor III

Percentage Contribution in pivot table based on three dimensions

Hi All,

I have a requirement to calculate the percentage sales of product contribution per market per country

and show the sales value of only those products which is giving 80% contribution.

So i have 3 dimensions(Country, Market, product) and 1 measure(sales).

I am using the following expression which is working fine in straight table. 

(RangeSum(Above( Sum(sales), 0, RowNo())))/
Aggr(NODISTINCT Sum(sales),market,country)

if(((RangeSum(Above( Sum(sales), 0, RowNo())))/
Aggr(NODISTINCT Sum(sales),market,country)) <='0.8', sum(sales))

But when i convert it into a pivot table, the percentage and sales are coming correctly at the product level, but the totals are not summing up at market and country level.

I tried using dimensionality, but showing incorrect results.

Doing Aggr and Sum is also not working.

Can someone help me to achieve this in Pivot table ? 

Thanks in advance

1 Reply
keerthanagowsi
Contributor III
Contributor III
Author

Can someone provide any inputs?