When I get down to level 6 of my nested condition, the UI won't show add action links for the yes/no options.
I want to check if a title starts with a,b,c,d,e,f, and couldn't figure out how to use the @or() operator nested, and switch statement won't work as I need startsWith and not equals.
So I figured I'd do an ugly nested if flow instead - which stops at 5 levels it seems.
Solved! Go to Solution.
Hi @MikaelSvenson,
Under your first condition, click the Advanced Mode, then following the example below to configure the nested or:
@or( startsWith(triggerBody()?['title'], 'A'), or( startsWith(triggerBody()?['title'], 'B'), or( startsWith(triggerBody()?['title'], 'C'), or( startsWith(triggerBody()?['title'], 'D'), startsWith(triggerBody()?['title'], 'E') ) ) ) )
Hope this helps,
Regards,
Michael
Hi @MikaelSvenson,
Yes, you are reaching the current Flow Definition Limits:
See the document reference:
Limits and configuration in Microsoft Flow
You may consider switch the flow structure with the following to extend the limits:
The @or() is Workflow Definition Language:
If you need any further assistance on this, please post back.
Regards,
Michael
Thank you. @or only supports two operands, and I couldn't figure out how to do nested @or's.
Can you propose how to write a flow/statement which checks if a variable starts with any of say 6 different start values?
Thanks,
Mikael
Hi @MikaelSvenson,
Under your first condition, click the Advanced Mode, then following the example below to configure the nested or:
@or( startsWith(triggerBody()?['title'], 'A'), or( startsWith(triggerBody()?['title'], 'B'), or( startsWith(triggerBody()?['title'], 'C'), or( startsWith(triggerBody()?['title'], 'D'), startsWith(triggerBody()?['title'], 'E') ) ) ) )
Hope this helps,
Regards,
Michael
I'll try that and report back later...didn't try nesting it like that..I tried or(or... , or...) etc. Thanks 🙂
Seems to work like a charm 😄
Btw, the samples for startsWith/endsWith are wrong on https://docs.microsoft.com/en-us/azure/logic-apps/logic-apps-workflow-definition-language. They use lastIndexOf as the sample.
Thanks,
-mikael
Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.
Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!
User | Count |
---|---|
15 | |
10 | |
3 | |
3 | |
3 |