Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

vanand3535
Contributor

Percentage in Stacked Bar Chart

I have a bar chart with

1-Dimension

3-Measure

All the 3 measures have different filters applied to it

When I am trying to find the percentage I'm not able to get 100%

Sometimes I'm getting more than 100% , sometimes less than 100%

As of now i'm using the formula for percentage is:-

count(fields)/count(total fields)

or

sum(fields)/

sum(total fields)

1 Solution

Accepted Solutions
YoussefBelloum
Esteemed Contributor

Re: Percentage in Stacked Bar Chart

Ok, I see , one more time

Try this:

=sum(sales)/sum(sales+profit+discount)

=sum(profit)/sum(sales+profit+discount)

=sum(discount)/sum(sales+profit+discount)

In %

23 Replies
YoussefBelloum
Esteemed Contributor

Re: Percentage in Stacked Bar Chart

Hi,

can you attach sample app or data ?

vanand3535
Contributor

Re: Percentage in Stacked Bar Chart

Please find the attachment

YoussefBelloum
Esteemed Contributor

Re: Percentage in Stacked Bar Chart

just re attach the file, nothing is attached now

vanand3535
Contributor

Re: Percentage in Stacked Bar Chart

The formulae used here is:-

Sum(Sales)/Sum(Total Sales)

Sum(CategoryName)/Sum(total CategoryName)

Sum(ProductName)/Sum(total ProductName)

Screenshot (662).png

Screenshot (663).png

vanand3535
Contributor

Re: Percentage in Stacked Bar Chart

I'm not finding any way to attach the app or data

or video and image attachment opting i'm getting

YoussefBelloum
Esteemed Contributor

Re: Percentage in Stacked Bar Chart

ok but here I can't see the issue.. can you create sample data ?

vanand3535
Contributor

Re: Percentage in  Stacked Bar Chart

I have sample data but how can  I attach the excel sheet here because here I'm only getting an option to attach image or video

YoussefBelloum
Esteemed Contributor

Re: Percentage in Stacked Bar Chart

Use advanced editor

Capture.PNG

vanand3535
Contributor

Re: Percentage in Stacked Bar Chart

I have attached the sample data ,

please find the attachment !

Community Browser