Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi,
I'm having some trouble with a string text column I have, its called: "Task Status" within Task status there are some blank values
Column:
Complete
Not Started
In Progress
Etc,
I followed some guides online and they are mostly geared up to creating measures of which the column needs to be numeric value to work, but I can't figure out how to pull a "0" for the count of a blank text string.
Can anyone help?
Thanks,
Solved! Go to Solution.
Try this -
Task Status Measure =
IF(
ISBLANK(SELECTEDVALUE('Table'[Task Status])),
0,
SELECTEDVALUE('Table'[Task Status])
)
Proud to be a Super User! | |
Hi @stevenlong85 ,
Use the following DAX formula to create a measure that counts blank values:
Count_Blank_Status =
CALCULATE(
COUNTROWS('TableName'),
ISBLANK('TableName'[Task Status])
)
If You Want to Replace Blanks with "0" or Another Default Value create a New Calculated Column in your table with this DAX formula:
Task_Status_Filled =
IF(
ISBLANK('TableName'[Task Status]),
"0", -- Replace with any value you want
'TableName'[Task Status]
)
Also you can replace the Blank Values (null values) in power query:
1- Go to power query, select the disered column, and choose replace values:
2- Now in Value to find keep blank and in replace with choose 0:
Now you can close and apply.
Try this -
Task Status Measure =
IF(
ISBLANK(SELECTEDVALUE('Table'[Task Status])),
0,
SELECTEDVALUE('Table'[Task Status])
)
Proud to be a Super User! | |
WOW! super fast response and this worked perfectly!
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
78 | |
78 | |
59 | |
35 | |
33 |
User | Count |
---|---|
100 | |
62 | |
56 | |
47 | |
41 |