Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
Anonymous
Not applicable

Power BI measure not matching data view

So I have a BI Measure that shows the percentage.

This is the measure:

 

Cost blank =
VAR __AmountBlank = CALCULATE(COUNT(X[Cost]), X[COST] = BLANK())
VAR __Total = COUNT(X[Cost])
RETURN
DIVIDE(__AmountBlank, __Total, -1)

 

The variable __AmountBlank returns the value 382 965.
When I go to the data view, and filter Cost on blank it returns 2 753 records.

 

I also tried ISBLANK(X[COST]) and X[COST] = "" (this returns an error) but nothing works.. 

How do I resolve this issue?

1 ACCEPTED SOLUTION
Uzi2019
Super User
Super User

Hi @Anonymous 
Please the below formula for count of blank rows. Take measure

Count =
Var A= COUNTROWS('Table')
var C= COUNTBLANK('Table'[Doc])
Return Divide(C,A,-1)
 
 
 
Don't forget to give thumbs up and accept this as a solution if it helped you!!!

View solution in original post

4 REPLIES 4
Uzi2019
Super User
Super User

Hi @Anonymous 
Please the below formula for count of blank rows. Take measure

Count =
Var A= COUNTROWS('Table')
var C= COUNTBLANK('Table'[Doc])
Return Divide(C,A,-1)
 
 
 
Don't forget to give thumbs up and accept this as a solution if it helped you!!!
Anonymous
Not applicable

This worked! Thanks a lot! 

 

Idrissshatila
Super User
Super User

HEllo @Anonymous ,

 

try

VAR __AmountBlank = CALCULATE(COUNTROWS('TableName'), X[COST] = BLANK())


Did I answer your question? Mark my post as a solution! Appreciate your Kudos
Follow me on LinkedIn linkedIn
Vote for my Community Mobile App Idea

Proud to be a Super User!




Anonymous
Not applicable

Interesting, did not try this yet! Unfortunately it does give the same result as the previous one..

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Kudoed Authors