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

"or" expression syntax

I am trying to create a conditon in Flow where I look at a field in a sharepoint list and if the data in the field is either "open' or "pending" the conditon is true.

 

However, I an struggling to understand the "or" expresion syntax within flow

 

Can someone help explain what is needed in the expression1 and expression2?

 

thanks,

 

Todd

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @thanke,

 

Could you please share a screenshot of your flow’s configuration?

Which data type does the field that you mentioned belong to in your SharePoint list?

Further, could you please show a bit more about expression1 and expression2?

I have created a SharePoint list on my side and the list include the filed which is a Choice type column. The value of Choice type column includes “Open”, “Pending” and “Complete”.

 

I have made a test on my side and please take a try with the following workaround:15.JPG

Within Condition box, click “Edit in advanced mode”, type the following formula:

 

@or(equals(items('Apply_to_each')?['Status']?['Value'], 'Open'),equals(items('Apply_to_each')?['Status']?['Value'], 'Pending'))

 

The flow works successfully as below:14.JPG

 

More details about Or expression, please check the following article:

https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-workflow-definition-language

 

 

Best regards,

Kris

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

2 REPLIES 2
v-xida-msft
Community Support
Community Support

Hi @thanke,

 

Could you please share a screenshot of your flow’s configuration?

Which data type does the field that you mentioned belong to in your SharePoint list?

Further, could you please show a bit more about expression1 and expression2?

I have created a SharePoint list on my side and the list include the filed which is a Choice type column. The value of Choice type column includes “Open”, “Pending” and “Complete”.

 

I have made a test on my side and please take a try with the following workaround:15.JPG

Within Condition box, click “Edit in advanced mode”, type the following formula:

 

@or(equals(items('Apply_to_each')?['Status']?['Value'], 'Open'),equals(items('Apply_to_each')?['Status']?['Value'], 'Pending'))

 

The flow works successfully as below:14.JPG

 

More details about Or expression, please check the following article:

https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-workflow-definition-language

 

 

Best regards,

Kris

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

Thanks.  Iwas trying otuse the "Edit in basic mode".  Is that not possible?  If not, can you help me understand when you would use the "Edit in basic mode"?  I would think I shoule be able to select the filed in the Sharepoint list as the first "Choose a value" and then select is equal to.  From here I would use the Expression option "or(expression1,espression2)"  when I select the second "Choose a value".  I just don't know what to use for "expression1 or expression2".  I am not familar with JSON and was hoping to keep it simple within the basic edit mode.  Is that not possible?

 

Screenshoot below

 

flow example.JPG

 

Thanks

Todd

 

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Users online (2,003)