Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Friends,
I want to create a bar chart which displays both count and its percentage and I'm using the below expressions for
1. Count(DISTINCT {<Maersk={'Y'}>}[Field Name])/Count(DISTINCT{$<[Carrier Name]={'Y'}>}[Field Name]) - percentage
2. Count(DISTINCT {<Maersk={'Y'}>}[Field Name]) - count of fields
The chart should be as below,

In the above chart, I can only able to show percentage but not the count. So, please help me guys to show both count and percentage in a single bar chart.
pfa,if u looking for the same ? u have write total syntax on ur expression tab.
Hi Siva,
By using two expressions you will get two bars for two expressions, you can select the relative option for one expression to show the % or if you are using stacked bar the second bar value will add to the first one and give you the total value as %.
Maybe someone here can give you the better answer
Hi,
You can do this using the DUAL function
So something like this (Sorry for any typos)
DUAL(num(Count(DISTINCT {<Maersk={'Y'}>}[Field Name])/Count(DISTINCT{$<[Carrier Name]={'Y'}>}[Field Name]) ,'0.00%'), Count(DISTINCT {<Maersk={'Y'}>}[Field Name]) )
I've attached an example
Thanks Adam, but it's not showing the count of fields...
Hi Siva,
What is it showing?
Adam
It displays only the percentage value but the count of fields is shown in y-axis, I need the count to be shown atleast on hovering it.

pfa,if u looking for the same ? u have write total syntax on ur expression tab.
Hmmm that is weird, I'd need to see your file to work it out really, but I suggest something isn't quite right with the formula.
Can you upload your file?
May be like this (using Adam's sample)
Thanks guys, I got it....