12 Replies Latest reply: Sep 28, 2017 4:37 PM by Heidi Woltz

# Percentage of specific amounts in Pivot Table

I am doing financials in qlikview and I need to show in the pivot table % of sales for each row.  See attached screenshot.

For example I am wanting to create a new column title % of sales, it will take each row and divide it by the total of the Title Row "Sales".  See the attached file called excel.

• ###### Percentage of specific amounts in Pivot Table

Hi,

Assuming your expression in the amount column is Sum(Amount) then try Sum(Amount)/Sum(TOTAL Amount) as the new expression for percentage.

Hope this helps,

Jason

• ###### Percentage of specific amounts in Pivot Table

Oops - sorry just re-read the question!

Try Sum(Amount)/Sum({<Title={Sales}>}TOTAL Amount)

Jason

• ###### Percentage of specific amounts in Pivot Table

Jason,That worked, but I need a bitmore.  It works great when there is one year in the column, but when I have more than one year not quite working.  How can I get this to only percentage of a that one colum.See attached.

• ###### Percentage of specific amounts in Pivot Table

Try Sum(Amount)/Sum({<Title={Sales},Year=>}TOTAL Amount)

• ###### Percentage of specific amounts in Pivot Table

Getting a little bit closer.  First I can't thank you enough for the help!!.  It is know calculating the percentage on all the, I just want it to calc for that specific column, so if I just choose 2012, it will calc on 2012.  If I choose 2011 and 2012, it will calc the sales on2012 only for that column and 2011 only on that colum.  I have attached a screen shot of how excel pivot table does it.THANKS

• ###### Percentage of specific amounts in Pivot Table

Have you added Year as a dimension?

• ###### Percentage of specific amounts in Pivot Table

Yes year is a dimension

• ###### Percentage of specific amounts in Pivot Table

Then I'm not sure why the first answer I gave isn't working.  Can you post your app at all?

• ###### Percentage of specific amounts in Pivot Table

Oh - hang on!  Try:

Sum(Amount)/Sum({<Title={Sales}>}TOTAL <Year> Amount)

• ###### Percentage of specific amounts in Pivot Table

Worked Perferctly, THANKS!!!!!

• ###### Percentage of specific amounts in Pivot Table

Coolio.

• ###### Re: Percentage of specific amounts in Pivot Table

I'm using the % of function in a P&L Pivot table, but it's only calculating the base amount as a %, everything else = #N/A. How do I correct this?