Forum Discussion
Display Percent rather than Count
- 9 years ago
Hi enterprised1,
We should write measure to show the correct percentage. Please follow the steps below to see if it would work:
- Under the data View, create a measure to calculate the count of Amount=800;
- Count800 = calculate(count(‘Table’[ID]), ‘Table’[Amount]=800)
- Create another measure to calculate the percentage:
- Precent = Divide([Count800],COUNT(‘Table’[ID]))
- Under the report View, in the Fields, click Precent, then click on % to format it. Select Card Visual and put the Precent into the values, it should show the correct percentage:
Using the quick calc here would always show 100%, as the total count is also filtered, but not the original total.
If any further help needed, please feel free to post back.
Regards
Hi enterprised1,
We should write measure to show the correct percentage. Please follow the steps below to see if it would work:
- Under the data View, create a measure to calculate the count of Amount=800;
- Count800 = calculate(count(‘Table’[ID]), ‘Table’[Amount]=800)
- Create another measure to calculate the percentage:
- Precent = Divide([Count800],COUNT(‘Table’[ID]))
- Under the report View, in the Fields, click Precent, then click on % to format it. Select Card Visual and put the Precent into the values, it should show the correct percentage:
Using the quick calc here would always show 100%, as the total count is also filtered, but not the original total.
If any further help needed, please feel free to post back.
Regards
v-micsh-msft Thanks for the suggestion! I'm not using Power BI Desktop, but I believe I can accomplish adding the Measure directly in the Excel file. I'll give that a try and will post back if I run into any issues.
Any ideas on if or how this can be accomplished within the Power BI service? I would rather be able to do it from the Power BI interface than go messing with the Excel file if I can avoid it.
Thanks!