Power Automate Condition if a String is Empty

Do you know how to check if a string is empty using Power Automate flow? Well, in this Power Automate tutorial, We will discuss how to check the condition if a string is empty using multiple conditions for example.

Let us check an example on the Power Automate condition if a string is empty.

Power Automate condition if a string is empty

Let us see how we can check the condition if a string is empty using Power Automate flow.

Here, we will create a variable to check if the task priority column which is of string data type is empty or not. And the flow will trigger when a new item is created or the existing item is modified on the SharePoint list.

To achieve this follow the below steps:

  • Create a new power automated flow by selecting +New flow -> Automated flow then enter the flow name.
  • Choose the trigger when an item is created or modified and click on the create option.
  • Configure the trigger with the Site Address and List Name here I have selected my SharePoint site and the SharePoint list Name (TaskList).
Example of Power Automate condition if blank
Power Automate condition if a string is empty
  • Select plus sign (+New Step)-> Add an action to initialize a variable for the task priority column:
  • Enter the variable name as TaskPriority value and choose the data type as a string and add dynamic content value as TaskPriority Value in the value section.
Power Automate condition if a string is empty
Power Automate condition if a string is empty
  • Click on the Next step and select condition control action to check if the task priority column has an empty value or not.
  • Then we will add the condition if the Task priority variable is equal to empty then it returns true value else false value.
TaskPriority Variable  is equal to empty
  1. TaskPriority Variable is equal to empty
  2. Operator: is equal to
  3. value: empty
Example of Power Automate condition if a string is empty
Example of Power Automate condition if a string is empty
  • Save the flow and Click the flow checker to check if any error occurs in the flow or not. If there is no error Select Test-> Manually-> Save & Test.
Test Power Automate flow example
Test Power Automate flow example

Here we will Create a new item in the SharePoint list, with the empty Task Priority value as below:

condition if a string is empty in Power Automate
condition if a string is empty in Power Automate

In the below screenshot, you can see it returns a true value because the TaskPriority column contains an empty value.

Power Automate condition if a string is empty example
Power Automate condition if a string is an empty example

This is how to check the condition if a string is empty using Power Automate flow.

See also  How to Reset Power Apps Combo Box

Power Automate condition check if a string is empty

Here we will see how we can check the condition check if a string is empty using Power Automate flow.

Initially, we will create a variable to check if the task priority column which is of string data type is empty or not using multiple conditions in Power Automate flow. And the flow will trigger when a new item is created or the existing item is modified on the SharePoint list.

To achieve this using multiple conditions, follow the steps:

  • Select +New flow -> Automated flow then enter the flow name. Choose the trigger when an item is created or modified and click create option.
  • Configure the trigger with the Site Address and List Name here I have selected my SharePoint site and the SharePoint list Name (TaskList).
Example of Power Automate condition if blank
Example of Power Automate condition if blank
  • Choose(+New Step)-> Add an action to initialize a variable for the task priority column:
  • Enter the variable name as TPV and choose the data type as a string and add dynamic content value as TaskPriority Value in the value section as below:
Power Automate condition check if a string is empty
Power Automate condition check if a string is empty
  • Then select condition control action and change the Condition to OR check if the task priority column has empty and secondly, we will check using the length formula.
  • If the Task priority variable passes either one of the conditions then it returns a true value or else a false value.
TPV is equal to empty
  1. TPV is equal to empty
  2. Operator: is equal to
  3. value: empty
length(variables('TPV')) is equal to 0
  1. Length: Function name
  2. TPV: Variable name
  3. Operator: is equal to
  4. value: 0
Power Automate condition if get items is empty
Power Automate condition if get items is empty

Add two compose actions as below if yes then displays the yes it empty else not empty as highlighted below:

is empty in Power Automate
is empty in Power Automate

Select Test-> Manually-> Save & Test to test the Power Automate flow. We will modify the existing item in the SharePoint list, with the empty Task Priority value as below:

Example of Power Automate condition if get items is empty
An example of a Power Automate condition is if the get items are empty

In the below screenshot, you can see it returns a true value because the TaskPriority column contains an empty value.

Example of Power Automate condition check if a string is empty
Example of Power Automate condition check if a string is empty

This is how to check condition check if a string is empty using Power Automate flow.

See also  Power BI Clustered Bar Chart + 7 Useful Examples

In this Power Automate tutorial, we have discussed how to check the condition if a string is empty and also covered the Power Automate condition check if a string is empty with an example.

You may also like:

>