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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Analitika
Post Prodigy
Post Prodigy

NOT ISBLANK not same as <> "" and not same as Filtered NOT BLANKS

NOT ISBLANK not same as <> "" and not same as Filtered NOT BLANKS 

 

WHY PBI so complicated? 👿

 

Analitika_0-1598033452966.png

_Sum = 
SUMX(
    VALUES(opzurant[SF]),
    CALCULATE(
        MAX(opzurant[Sum])
    )  
)
--------------------------------------
_Sum_f = 
SUMX(
    VALUES(opzurant[SF]),
    CALCULATE(
        MAX(opzurant[Sum]),
        FILTER(opzurant,NOT ISBLANK(opzurant[SF]))
    )  
)
--------------------------------------
_Sum_f_2 = 
SUMX(
    VALUES(opzurant[SF]),
    CALCULATE(
        MAX(opzurant[Sum]),
        FILTER(opzurant,(opzurant[SF])<> "")
    )  
)

In screenshot showing EMPTY but dont work with BLANKS too!!!
1. In first example filtered NOT is BLANK hides blanks, Like expected but need do the same from measure,  sum is GOOD  65.000

2. Do not hiding Blanks

3. Does not hide blanks, sum is wrong must be 87.500, also do not filter blanks and add blanks sum to total, must be 65.000

4. Hides blanks, wrong sum

 

wtf?

 

1 ACCEPTED SOLUTION
v-xicai
Community Support
Community Support

Hi @Analitika ,

 

NOT ISBLANK() is usually used in IF function to check if the specific situation is TRUE or FALSE, and when it is used as context filter expression in FILTER function , it will return both TRUE() and FALSE() result , which have no filter effect for the data, so it returns all the data .  If you need to use the NOT ISBLANK(), you may create measure like DAX below.

_Sum_f =
SUMX (
    VALUES ( opzurant[SF] ),
    CALCULATE (
        MAX ( opzurant[Sum] ),
        FILTER ( opzurant, IF ( NOT ( ISBLANK ( opzurant[SF] ) ), TRUE (), FALSE () ) )
    )
)

Best Regards,

Amy 

 

Community Support Team _ Amy

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
v-xicai
Community Support
Community Support

Hi @Analitika ,

 

NOT ISBLANK() is usually used in IF function to check if the specific situation is TRUE or FALSE, and when it is used as context filter expression in FILTER function , it will return both TRUE() and FALSE() result , which have no filter effect for the data, so it returns all the data .  If you need to use the NOT ISBLANK(), you may create measure like DAX below.

_Sum_f =
SUMX (
    VALUES ( opzurant[SF] ),
    CALCULATE (
        MAX ( opzurant[Sum] ),
        FILTER ( opzurant, IF ( NOT ( ISBLANK ( opzurant[SF] ) ), TRUE (), FALSE () ) )
    )
)

Best Regards,

Amy 

 

Community Support Team _ Amy

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Greg_Deckler
Community Champion
Community Champion

@Analitika - Yes, that's correct, I did a bunch of testing on this once, let me look for the thread. For your total, This looks like a measure totals problem. Very common. See my post about it here: https://community.powerbi.com/t5/DAX-Commands-and-Tips/Dealing-with-Measure-Totals/td-p/63376

Also, this Quick Measure, Measure Totals, The Final Word should get you what you need:
https://community.powerbi.com/t5/Quick-Measures-Gallery/Measure-Totals-The-Final-Word/m-p/547907



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
harshnathani
Community Champion
Community Champion

Hi @Analitika ,

 

see this video to understand BLANK(), NULL , ZEROS and EMPTY.

 

https://www.youtube.com/watch?v=C26DQkb4hyY

 

https://xxlbi.com/blog/different-blanks-in-dax/

 

Regards,
Harsh Nathani
Did I answer your question? Mark my post as a solution! Appreciate with a Kudos!! (Click the Thumbs Up Button)

I understand all of this, i dont understand PBI as it is terrible


WHY  NOT ISBLANK()  change SUM ? 😱

amitchandak
Super User
Super User

@Analitika , try like

_Sum_f_2 = 
SUMX(
    VALUES(opzurant[SF]),
    CALCULATE(
        MAX(opzurant[Sum]),
        FILTER(opzurant,(opzurant[SF])<> blank())
    )  
)
Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Result is same like in 4 

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors