Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello.
I have created a dashboard for my project that includes various demographic information (e.g. gender, nationality, vulnerabilities...etc.). Each case may contain multiple vulnerabilities.
I want my graph on Power BI to include the values for each individual vulnerability (similar to countif on excel). Most importantly, I didn't want the cells that contain multiple vulnerabilities to result in a new aggregated type of vulnerability.
Through a google search, I was able to find the following DAX formula which I repeated the same steps for all of the vulnerabilities:
Hello @tamerj1
Thanks for the advice.
I tried this but it resulted in the aggregation that I was trying to avoid.
The problem here is that some cases have multiple vulnerabilities at once but I don't want to highlight the combination of vulnerabilities.
Rather, the graph that I want would only show the 6 primary categories as such:
This graph was created from the calculated measures using the formula I had shared in the first message.
Is there a way to accomplish this without severing the connection to the slicers?
@gghanem
Just create a new calculated column in the data table that categorize/group them into 6 groups.
Somthing like:
Category =
SWITCH (
TRUE ( ),
'Table'[Vulnerability] IN { "CHILD/YOUTH", "CHILD /YOUTH", "CHILD/ YOUTH", "CHILD / YOUTH" }, "CHILD/YOUTH",
etc..
Hi @gghanem
The ALL function removes all filters. As of you measures you can use
Child/ Youth =
CALCULATE (
COUNT ( Sheet1[Vulnerability] ),
Sheet1[Vulnerability] = "Child/ Youth"
)
However there is no need to create a seperate measure for each Vulnerability rtaher you can place the [Vulnerability] column in the legend of the donut chart and place the following measure in the values
Count = COUNT ( Sheet1[Vulnerability] )
or even
Count = COUNTROWS ( Sheet1 )
and it should work
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 6 | |
| 6 | |
| 4 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 25 | |
| 21 | |
| 10 | |
| 8 | |
| 8 |