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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Expression Evaluation ...
Power Automate
Unanswered

Expression Evaluation Failed error

(0) ShareShare
ReportReport
Posted on by 261

I have a flow 'When item is created' that updates an item based on a library/company corporate directory, this will only take a few seconds to update and terminate.

 

I have a second flow based also on 'When item is created' followed by a delay step of two minutes and a switch step where the condition is set from a column that has been updated from the first flow.

I am working on the presumption that this flow is delayed by 2 minutes which would give enough time for the first flow to terminate and update the item to which the Switch condition would work, however I get the below error:

 

ExpressionEvaluationFailed. The execution of template action 'Switch' failed: The result of the evaluation of 'scope' action expression '@triggerOutputs()?['body/Crew_x0020_Type']' is not valid. It is of type 'Null' but is expected to be a value of type 'String, Integer

 

Is the above error due to the fact that the switch based column is empty? should it not be updated by the previous flow and only progress after the delay?

 

Capture.png

Any ideas on how to solve this?

Categories:
I have the same question (0)
  • Expiscornovus Profile Picture
    33,189 Most Valuable Professional on at

    Hi @mtagliaferri,

     

    Can you share a screenshot of outputs of the When an item is created action from the failed flow run. This should show is if the crew_type field was empty.

     

    Btw, is the crew_type a single line of text column or a choice field?

  • mtagliaferri Profile Picture
    261 on at

    @Expiscornovus I believe I have solved the issue!

     

    The crew_type a single line of text column.

     

    I have checked the output of 'When item is create' and there is not data, so I inserted a Get Item Step after the delay,

    Capture 2.png

    This gets the value needed in the column

    Capture 3.png

    I have run a test and it appears to have solved the issue.

     

    However can you advise if I still need the delay? just wondering how the dynamic of the flow runs with the get item? would the get item wait till the first flow has terminated or would it run in an error?

  • Expiscornovus Profile Picture
    33,189 Most Valuable Professional on at

    Hi @mtagliaferri,

     

    Apologies, I now noticed that you are using the same trigger action for both flows.

     

    Since you are updating the item in the first flow I would probably use a different trigger action for the second flow.

     

    I would suggest the when an item or a file is modified trigger action:

    https://docs.microsoft.com/en-us/connectors/sharepointonline/#when-an-item-or-a-file-is-modified

     

    However, that means you have to rebuild your second flow a bit. Benefit of that will be that you won't be needing the delay though.

     

     

  • mtagliaferri Profile Picture
    261 on at

    Hi @Expiscornovus 

    I have considered when an item or a file is modified trigger action, but the item is set to be modified various times and it would trigger the flow again; I would have to create a further check column to stop the flow from triggering.

     

    I have also thought of get changes to an item and set it to Crew_Type as this would only be updated once from the first flow.

     

    Any other suggestions on how to stop this specific flow from re-triggering are greatly accepted 🙂 

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard