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

Forms > Flow > SharePoint: Need help with an Expression

Hi all,

 

We're using MS Forms to capture quantities of weight of various products which are sent to a SP list by FLOW.

So far so good, and that works ok, but.

 

My question is:

If the Form is completed for 1,000 of "Product A" i need the sharepoint list to be updates but for Poducts B, C, & D to be "0".

And so if the next Form is submitted with 500 of Product C I need the entries for A, B, & D to be 0 and so on.   

 

The problem i'm having is the list will update with the quantities without problem, but all entries of "0" are blank. 

Please help with the expression of =IF(cloumn entry is completed add the quantity), otherwise make "0")

 

Thanks

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Willemijn
Level 8

Re: Forms > Flow > SharePoint: Need help with an Expression

Hi, 

 

Your expression could look like: 

 

if(equals(outputs('Get_response_details')?['body/r78c52caf5e0e4fb2b39404f10a096cf2'],''),'0',outputs('Get_response_details')?['body/r78c52caf5e0e4fb2b39404f10a096cf2'])

 

where te body/ is the guid of product A in my test: 

2019-07-15 13_44_11-Edit your flow _ Microsoft Flow.png

3 REPLIES 3
Super User
Super User

Re: Forms > Flow > SharePoint: Need help with an Expression

Hi @PaulD 

If your values are null and you want to default them to 0 then you can make use of the Coalesce expression.

Within your Update Sharepoint action ,for each sharepoint quantity set it to an expression similar to coalesce(FORM_COLUMN,0) where FORM_COLUMN is the value from your Form submission.

If the FORM_COLUMN value is null then the expression will use the 0 value instead.

 

Details on coalesce can be found here https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference#c...

 


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

Proud to be a Flownaut!


Willemijn
Level 8

Re: Forms > Flow > SharePoint: Need help with an Expression

Hi, 

 

Your expression could look like: 

 

if(equals(outputs('Get_response_details')?['body/r78c52caf5e0e4fb2b39404f10a096cf2'],''),'0',outputs('Get_response_details')?['body/r78c52caf5e0e4fb2b39404f10a096cf2'])

 

where te body/ is the guid of product A in my test: 

2019-07-15 13_44_11-Edit your flow _ Microsoft Flow.png

PaulD
Level: Powered On

Re: Forms > Flow > SharePoint: Need help with an Expression

Thank you @Willemijn  & @LeeHarris  for your suggestions.

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020

thirdimage

Flow 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 Flow Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 50 members 4,970 guests
Please welcome our newest community members: