web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / If IsBlank formula not...
Power Apps
Answered

If IsBlank formula not behaving as expected

(0) ShareShare
ReportReport
Posted on by 13

I have a patch function which should write in a Sharepoint List the value for "Compiled" if it is not blank, or the value for "Median" if else.

 

I wrote the following statement for the patch: 

Patch(results;First(Filter(results; ID= compiled_ID ) ); { evaluation: If(IsBlank(compiled);median;compiled)})

For some reason, it only works on reverse:

Patch(results;First(Filter(results; ID= compiled_ID ) ); { evaluation: If(Not(IsBlank(compiled));compiled;median)})

 

Does anyone have an explanation for this? Is it a known bug?

Thanks!

Categories:
I have the same question (0)
  • Verified answer
    GarethPrisk Profile Picture
    2,828 on at

    It may depend on the column type, and what value it may have within it. There are scenarios where a string like "" is actually there, and that's not actually a blank value.

    Another option, is to leverage Coalesce (which uses first non-null value).

    Patch(results;First(Filter(results; ID= compiled_ID ) ); { evaluation: Coalesce(compiled;median)})

    https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-isblank-isempty

     

    I have seen some mixed behavior with IsBlank, IsBlankOrError, etc. but it's usually traceable (i.e. has a reason for not working - maybe data mismatched, data source varations, etc.). It's definitely preferable to having to write complicated statements to get the output you want.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 530

#2
WarrenBelz Profile Picture

WarrenBelz 459 Most Valuable Professional

#3
Haque Profile Picture

Haque 314

Last 30 days Overall leaderboard