Forum Discussion
Show value with no data when filtering
Hello! I am a new Power BI user. I did some research on my question but was not able to find a solution.
I am trying to show a visualization (bar graph or matrix) that counts how many bugs are in each Sprint. For example, 2 bugs in Sprint 1, 3 bugs in Sprint 2, etc. See below for the column structure. I used basic filtering to filter out the "User Story" category. The issue is that Sprint 3 does not have any bugs, so it does not show up in my visualization, even when I select "Show items with no data." I would like it to show up in my visualization but am not sure how. Any suggestions? Not sure if I need to rearrange my columns, create a new measure, etc.
| Sprint | Type |
| 1 | User Story |
| 1 | User Story |
| 1 | Bug |
| 1 | Bug |
| 2 | User Story |
| 2 | Bug |
| 2 | Bug |
| 2 | Bug |
| 2 | User Story |
| 3 | User Story |
| 3 | User Story |
| 3 | User Story |
| 3 | User Story |
| 3 | User Story |
Anonymous solution attached, I hope this is what you are looking for.
6 Replies
- parry2kSuper User
Anonymous you can achieve with following steps:
create new table for type using dax below
TypeTable = VALUES( YourTable[Type] )
Now create a measure for count using following DAX
Count Rows = CALCULATE( Countrows( YourTable ), TREATAS( VALUES( TypeTable[Type] ), YourTable[Type] ) )
Now on graph, use type on x-axis and slicer from new typetable
And it should work.
- AnonymousNot applicable
Thanks parry2k , I appreciate the help.
I created the suggested TypeTable and Count Rows measures, but was unable to get the desired result (still cannot see Sprint 3 in the bar graph). I want to keep the Sprint field on the x-axis, not the Type field (see image in original post). Let me know if the data I pulled into the Axis, Type, and Count Rows fields are incorrect.
- parry2kSuper User
Anonymous can you share sample data in excel