Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more.
Get startedGrow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.
Hello Dear Community,
There's something I don't understand about data bars.
In the example below, the total amount of sales is 1,56 M, and the top customer (the list is arranged by total sales) appears to have a bar almost completely filled, with a sales amount of 279 K. The filling is not proportional to the total sales amount right?
What am I missing here?
The bar is configured like this:
Many thanks in advance 🙂
Solved! Go to Solution.
Hi @LuisNC ,
When you set the conditional formatting with data bars, you can only set the maximum and minimum values, you can't set them as percentages. So we need to create a percentage column and then set the conditional formatting for it. I created a sample pbix file(see the attachment), please check if that is what you want.
1. Create a measure as below to get the percent of per customer
Percent =
VAR _allamount =
CALCULATE ( SUM ( 'Table'[Amount] ), ALL ( 'Table' ) )
RETURN
DIVIDE ( SUM ( 'Table'[Amount] ), _allamount )
2. Add the new measure on the visual and configure conditional formatting for it as below screenshot
If the above one can't help you, please provide some raw data in your tables(exclude sensitive data) with Text format and your expected result with backend logic and special examples. It would be helpful to find out the solution. You can refer the following link to share the required info:
How to provide sample data in the Power BI Forum
And It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.
How to upload PBI in Community
Best Regards
Sorry @v-yiruan-msft for my very late reply, and thank you very much for your reply.
The only "problem" is that the table of the example is taking a bit of space already in the report page.
So I don't want to add a new column. From your explanation I understand that it's not possible to create the proportional bar in the total amount column, as an extra column is required.
However I really appreciate your explanation, which makes sense despite I am a newbie in the world of data 🙂
I understand your explanation and your code, and it will be helpful in the future for sure!
Thank you very much again, and all the best!
Hi @LuisNC ,
When you set the conditional formatting with data bars, you can only set the maximum and minimum values, you can't set them as percentages. So we need to create a percentage column and then set the conditional formatting for it. I created a sample pbix file(see the attachment), please check if that is what you want.
1. Create a measure as below to get the percent of per customer
Percent =
VAR _allamount =
CALCULATE ( SUM ( 'Table'[Amount] ), ALL ( 'Table' ) )
RETURN
DIVIDE ( SUM ( 'Table'[Amount] ), _allamount )
2. Add the new measure on the visual and configure conditional formatting for it as below screenshot
If the above one can't help you, please provide some raw data in your tables(exclude sensitive data) with Text format and your expected result with backend logic and special examples. It would be helpful to find out the solution. You can refer the following link to share the required info:
How to provide sample data in the Power BI Forum
And It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.
How to upload PBI in Community
Best Regards
User | Count |
---|---|
79 | |
74 | |
62 | |
61 | |
45 |
User | Count |
---|---|
108 | |
100 | |
91 | |
83 | |
61 |