cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
willy30870 Helper I
Helper I

condition not working

Hello again Smiley Happy,

 

I have a new mistake with conditionnal step that are in a "apply to each" loop : 

she is still true so she should not.

 

my condition : 

not(empty(outputs('Compose_2')))    is egual to  true (expression)

 

I want to know if the compose 2 output is empty or not

condition4.JPG

 

but I have always the same result whereas the output compose_2 switch well...condition3.JPG

 

condition2-1.JPG

 

condition2.JPG

 

If someone have an idea...thank you!

 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Re: condition not working

 

Hi @willy30870 ,

 

The reason for this result is that the value in Compose is actually space, so the result of the condition is not empty.

Although there is no specific value, it will still be treated as a character, so the result is always true.

 

Based on this situation, you could use the length() function to determine the number of characters directly in Condition. If it is equal to 1, it implies that the value here maybe just space and there is no actual value.

Expression reference:

length(outputs('Compose'))

Image reference:

8.PNG

 

Best Regards,

Community Support Team _ Barry
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

5 REPLIES 5
Super User
Super User

Re: condition not working

Hi @willy30870 ,

 

Thanks for the screenshot. 

 

I did tested this and I got the expected results.

 

Find the length of the compose output using the below expression.
 
length(outputs('Compose_2'))
 
You must have a blank value returning.
 
Let me know the results.
 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks

 


Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blog
willy30870 Helper I
Helper I

Re: condition not working

I just tryed your solution but it's not working for me...

Super User
Super User

Re: condition not working

Hi @willy30870 

 

Thanks for the quick response.

 

What I meant is find the length of the compose output in a variable. If it's more than zero that means there is something in the compose output.

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blog
willy30870 Helper I
Helper I

Re: condition not working

works.JPG

 

It's working, I find it a little complicated but it works.

 

in case :
I have a table of data with a "select" step and 2 columns. I want to hide column 2 when it's empty.
if there is another solution than the one above I am interested!

Community Support
Community Support

Re: condition not working

 

Hi @willy30870 ,

 

The reason for this result is that the value in Compose is actually space, so the result of the condition is not empty.

Although there is no specific value, it will still be treated as a character, so the result is always true.

 

Based on this situation, you could use the length() function to determine the number of characters directly in Condition. If it is equal to 1, it implies that the value here maybe just space and there is no actual value.

Expression reference:

length(outputs('Compose'))

Image reference:

8.PNG

 

Best Regards,

Community Support Team _ Barry
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

Helpful resources

Announcements
firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Automate Community!

firstImage

Now Live: Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Users online (7,652)