Skip to main content

Notifications

Community site session details

Community site session details

Session Id : 9btURu+RhOdhz03giHgFSK
Power Automate - Building Flows
Suggested answer

Cannot set a value to Zero if null or empty

Like (0) ShareShare
ReportReport
Posted on 17 Mar 2025 03:21:04 by 4
Hi
 
I am trying to take form data and add it to a sharepoint list. The flow fails if the user has not entered any data as the output is expecting a number.
 
So have added a condition to check if the data is null or empty.
 
I am trying to set True so that it will change the value to 0. However, I cannot use 'Set Variable' as it wants a name but makes that field read-only 
 
 
And Initialize Variable does not work as it creates an error that it cannot be nested below a check field value condition. Seemingly leaving me with no way to update the value.
 
Any ideas?
  • Building with Why Profile Picture
    197 on 17 Mar 2025 at 12:47:46
    Cannot set a value to Zero if null or empty
    You initialize variables outside of any actions and set or append inside of actions.  
     
    In your condition all you need is to say null.  you do not need an equation to say equals null.  That is what the rest of the condition is doing.
     
    I also do not see an Apply to each, so not sure why the left side of your Condition is Current item
     
    Do you have an example of the output when the desired number is present?  If so can you screenshot and share?
  • Suggested answer
    ankit_singhal Profile Picture
    415 Super User 2025 Season 1 on 17 Mar 2025 at 05:21:59
    Cannot set a value to Zero if null or empty
    You can check items in your output. if there are more then one then you can perform action accordingly. 
     
    Note: Please mark verified, if it is useful for you 

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

Thomas Rice – Community Spotlight

We are honored to recognize Thomas Rice as our March 2025 Community…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,513 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,479 Most Valuable Professional

Leaderboard
Loading started