# New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Contributor

## Percentage calculation

Hi Experts,

I have a  pivot table like below from Measure please help me to calculate the Percentage column

Dimension            Measure(Count(ID))                  Percentage

Sales

Product 1               43                                              -

Product 2               21                                             21/43 = 48.84%

Product 3               22                                             22/43=51.16%

Division

Product 1               4                                              -

Product 2               1                                            1/4 = 25.00%

Product 3               3                                             3/4=75.00%

1 Solution

Accepted Solutions
MVP

## Re: Percentage calculation

Try this

Sum({<Dim2 -= {'Product1'}>} Ids)/Sum(TOTAL <Dim1> {<Dim2 = {'Product1'}>} Ids)

4 Replies
MVP

## Re: Percentage calculation

May be this

Count(ID)/Count(TOTAL {<Division = {'Product 1'}>} ID)

or

Count({<Division -= {'Product 1'}>} ID)/Count(TOTAL {<Division = {'Product 1'}>} ID)

Contributor III

## Re: Percentage calculation

Try,

Count(ID)/max(Total Count(ID))

Contributor

## Re: Percentage calculation

Hi Sunny,

Thanks for your reply. I have tried both expression which you have mentioned. But those are not working. Please find the below attached sample app with expected output.

Here Dim1 Division Product1 sum need to use for dividing remaining two products same like Dim1 Sales Product1 sum need to use for dividing remaining two products.

MVP

## Re: Percentage calculation

Try this

Sum({<Dim2 -= {'Product1'}>} Ids)/Sum(TOTAL <Dim1> {<Dim2 = {'Product1'}>} Ids)