- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Two values in 100% stacked bar, but show label for only one
How do I show label only for the value (utilization rate) being represented in light blue here?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @diogobraga2,
In fact, you can also use Dax formula to create a table with unpivoted records. Please refer to the below blog to learn how to use 'UNION' and 'SELECTCOLUMNS' functions to create a calculated table with expanded records:
Regards,
Xiaoxin Sheng
If this post helps, please consider accept as solution to help other members find it more quickly.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
HI @diogobraga2 ,
I'd like to suggest you do 'unpivoted columns'(query editor) on your value fields 'utilization rate' and 'not utilization rate', then you can modify your visual design to use 'attribute' on legends and 'value' on values.
Unpivot columns (Power Query)
After these operations, you can simply use filters to control which attributes to display.
Regards,
Xiaoxin Sheng
If this post helps, please consider accept as solution to help other members find it more quickly.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
By the way, the original dataset has only 'utilization rate' and that's the value that matters. I create the 'not utlization rate' by calculating 1-'utilization rate' since 100% is the maximum and I must show the utilzation out of 100%. Is there another way to show the 'utilzation rate' within a 100% bar axis to visualize this, without creating the 'not utilization rate' calculation therefore not needing to pivot to rows. Any ideas here?
If creating the 'not utilization rate' calculated column (the way I am doing now) is the only way...then it sounds like I will have to create another table to pivot the columns to rows.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @diogobraga2,
In fact, you can also use Dax formula to create a table with unpivoted records. Please refer to the below blog to learn how to use 'UNION' and 'SELECTCOLUMNS' functions to create a calculated table with expanded records:
Regards,
Xiaoxin Sheng
If this post helps, please consider accept as solution to help other members find it more quickly.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@v-shex-msft can you please provide your feedback on this?
I got the following error message:
DAX comparison operations do not support comparing values of type Number with values of type Text. Consider using the VALUE or FORMAT function to convert one of the values.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @diogobraga2 ,
It seems like your utilization column stored numeric values and you are trying to compare text value with numbers. For this scenario, I'd like to suggest you use blank() to replace "" to fix this issue.
Regards,
Xiaoxin Sheng
If this post helps, please consider accept as solution to help other members find it more quickly.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks. I uploaded the file here:
https://drive.google.com/open?id=15oa3vFFpqyit4Qfhk0ErSN4eKE5zPeyA

Helpful resources
Subject | Author | Posted | |
---|---|---|---|
09-11-2024 02:16 AM | |||
02-13-2024 11:10 AM | |||
04-10-2024 10:23 AM | |||
02-15-2023 10:13 AM | |||
08-17-2021 07:12 PM |
User | Count |
---|---|
132 | |
106 | |
85 | |
55 | |
46 |