cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
cah2035
Helper II
Helper II

Compose action skipped due to Condition, but gives a null value that I do not want

Hello, 
I have a flow that is checking in a source if a Sample ID exists. For all that do not exist, I am composing a list. However, for the ones that do exist, the compose action gives them a null value. 

First up is the "Apply to All" action which goes through each Sample ID to check if it exists, when it does not, a compose is created to hold the Sample ID. Once it goes through all items, I have another Compose action that takes the Outputs from all the Compose actions within the Apply to All. 

 

Sample1.png

Sample2.png

 

However, for items where the Sample ID does not exist, I get the "ActionBranchingConditionNotSatisfied" message, which is expected since the condition is not running that Compose action. But it ends up giving me the "Null" value in the final compose action. How can I stop this from happening?

 

Sample3.png

1 ACCEPTED SOLUTION

Accepted Solutions
Jronash
Solution Supplier
Solution Supplier

If you want to construct your array using this method, you're not going to be able to avoid those null values.  Fortunately, it's easy to remove them with the Filter array action.  Just do something like this:

filter.png

View solution in original post

2 REPLIES 2
Jronash
Solution Supplier
Solution Supplier

If you want to construct your array using this method, you're not going to be able to avoid those null values.  Fortunately, it's easy to remove them with the Filter array action.  Just do something like this:

filter.png

View solution in original post

@Jronash  That was perfect, thank you!

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (1,572)