cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
CGILL
Level: Powered On

Coalesce not behaving as expected

So I'm trying to make use of coalesce to return an alternate string if a field is blank... I've setup the following test flow

Annotation 2019-04-01 162233.png

 

In the Compose 3 action is the following formula, which i would expect to return 'lk' when there is no value of TaskCurrentReported02:

coalesce(body('Parse_JSON')?['TaskCurrentReported02'],'lk')

 In the Compose 2 action is the following formula, which i would also expect to return 'lk' when there is no value of TaskCurrentReported02:

if(empty(body('Parse_JSON')?['TaskCurrentReported02']),'lk',body('Parse_JSON')?['TaskCurrentReported02'])

However when i run the test, i see nothing in the inputs/outputs of Compose 3, but i get the correct answer in Compose 2... I'm trying to save myself what amounts to a ton of writing using Compose 2 method in favor of the shorter/more efficient Compose 3... but if i can't get it working, i guess i'll have to use Compose 2. 

Annotation 2019-04-01 162233.png

Hoping someone can help me understand what is going on here... 

2 REPLIES 2
Highlighted
Community Support Team
Community Support Team

Re: Coalesce not behaving as expected

Hi @CGILL ,

 

Thanks for feedback.

 

The issue could be reproduced by me.

 

Please use if function as a temporary workaround.

 

I will help confirm this issue and back to you later.

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
J_K_
Level: Powered On

Re: Coalesce not behaving as expected

It's been a few months and I have the same issue now. This renders the coalesce function useless... and leads to much wasted time.

Helpful resources

Announcements
firstImage

Incoming: New and improved badges!

Look out for new contribution recognition badges coming SOON!

firstImage

Power Platform Online Conference

Join us for the first ever Power Platform Online Conference!

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!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Power Automate Community Video Gallery!

Top Solution Authors
Top Kudoed Authors
Users online (4,391)