web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Switch Case Set Variab...
Power Automate
Unanswered

Switch Case Set Variable not working consistently

(0) ShareShare
ReportReport
Posted on by 16

In one of our workflow, we have switch case statement within do until with set variables that navigates to different case. At times, the Do loop is completed without transfering to case statement.

NoNameOH_0-1593468606121.png

Even though value is what is expected in the Case Statement, some times it's  ending the loop without going to the case statement.

 

This behavior is inconsistent since it works at times. This used to work without any issues and we are seeing this change today; Either when approved or rejected it's not working correct.

 

How do we fix this issue?

Categories:
I have the same question (0)
  • abm abm Profile Picture
    32,985 Most Valuable Professional on at

    Hi @NoNameOH 

     

    This could be the timeout of Do until loop which is default to a minute (60 seconds).

     

    https://powerusers.microsoft.com/t5/General-Power-Automate/Do-Until-Need-help-understanding-limits/td-p/371374

     

    There won't be any errors of timeout. It simply skips the Do Until loop and execute the next step after 60 seconds.

     

    Try increasing the limit and see if that works or not.

     

    Thanks

     

    Thanks

     

     

  • NoNameOH Profile Picture
    16 on at

    What's the max limit that can be set ? This powerautomate runs at the tenant level. Is there any way to prevent it from happenning?

     

  • abm abm Profile Picture
    32,985 Most Valuable Professional on at
  • NoNameOH Profile Picture
    16 on at

    Does it continuously check the do until loop if so, what's the time frame? if the action is not completed within 72 hours , will it time out?

     

    The Do until has a couple of approvals it goes  to next state when the approval in the previous state is complete. So, the Do until has to stay active for 30 days. I was planning to cap to 5000 iterations with timelimit P30D. Should we add delays to every switch/case ? if so, can you recommend some limits.

     

     

     

  • abm abm Profile Picture
    32,985 Most Valuable Professional on at

    Hi @NoNameOH 

     

     I haven't tested to confirm it but my best guess is it will timeout. 

     

    You can set timeout in approvals.

     

    https://www.o365dude.com/2018/06/02/timeout-flow-approvals/

     

    Thanks

     

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 552

#2
Valantis Profile Picture

Valantis 388

#3
11manish Profile Picture

11manish 375

Last 30 days Overall leaderboard