# Need to Update Workflow When Certain executions are still in "Running" State

**URL:** <https://developer.sailpoint.com/discuss/t/need-to-update-workflow-when-certain-executions-are-still-in-running-state/24464>\
**Category:** SHF Discussion and Questions\
**Tags:** identity-security-cloud\
**Created:** [January 18, 2024, 5:38pm UTC](https://developer.sailpoint.com/discuss/t/need-to-update-workflow-when-certain-executions-are-still-in-running-state/24464 "2024-01-18T17:38:58Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![DFuyal](https://avatars.discourse-cdn.com/v4/letter/d/74df32/32.png) [@DFuyal](https://developer.sailpoint.com/discuss/u/DFuyal)\
**Post date:** [January 18, 2024, 5:38pm UTC](https://developer.sailpoint.com/discuss/t/need-to-update-workflow-when-certain-executions-are-still-in-running-state/24464/1 "2024-01-18T17:38:58Z")

</div>

I need to update an email template inside a workflow but while I see the workflow executions, certain executions are still in “Running” state which were in running state since 3-4 days. I think that’s a bug and idnow team are still improving workflows efficiency. I need to disable the workflow to update and need to update the template. In that case, will the executions that are in “Running” state gets terminated? What is the best possible way to update the workflow if some of the executions are in state other than “Completed” such as “pending”, “Running” etc. Any thoughts?

---

<div class="post-metadata">

**Author:** ![fatimahm](https://avatars.discourse-cdn.com/v4/letter/f/3d9bf3/32.png) [@fatimahm](https://developer.sailpoint.com/discuss/u/fatimahm)\
**Post date:** [January 18, 2024, 5:52pm UTC](https://developer.sailpoint.com/discuss/t/need-to-update-workflow-when-certain-executions-are-still-in-running-state/24464/2 "2024-01-18T17:52:08Z")

</div>

Hello @DFuyal,

You need to disable the workflow to be able to update it. It’s required even by API. Otherwise, you’ll get an erro

 ![image](https://global.discourse-cdn.com/sailpoint/original/2X/8/89b186b0310312ad098b4d8b2c4ad1a2a6e5b67a.png)

The executions that are taking long time to be executed generally end up failing.

Regards,

---

<div class="post-metadata">

**Author:** ![jsosa](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/jsosa/32/31578_2.png) [@jsosa](https://developer.sailpoint.com/discuss/u/jsosa)\
**Post date:** [January 18, 2024, 7:25pm UTC](https://developer.sailpoint.com/discuss/t/need-to-update-workflow-when-certain-executions-are-still-in-running-state/24464/3 "2024-01-18T19:25:55Z")

</div>

Hi @DFuyal I have suffered it several times. You have to cancel it via API. First you have to look up you workflow id:

 ![image](https://global.discourse-cdn.com/sailpoint/original/2X/6/627f92d8aa6ef8745dcbce84785e4136548bb3aa.png)

Then, you have to find workflow executions with running/pending state for that workflow id, and finally cancel them.  
 ![image](https://global.discourse-cdn.com/sailpoint/original/2X/2/261c69a43215eed34f56efc141b17a8be36e5272.png)

One or two times this was not enough, in that cases I had to open a case to ask Sailpoint to kill workflow executions.

One thing I noticed, is that if some workflow goes into execution state and takes some time, is preferable to go take a coffee and come later, because if you trigger more workflows you will stuck more the system.

---

<div class="post-metadata">

**Author:** ![jsosa](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/jsosa/32/31578_2.png) [@jsosa](https://developer.sailpoint.com/discuss/u/jsosa)\
**Post date:** [January 18, 2024, 7:27pm UTC](https://developer.sailpoint.com/discuss/t/need-to-update-workflow-when-certain-executions-are-still-in-running-state/24464/4 "2024-01-18T19:27:18Z")

</div>

> [@DFuyal](#):
>
> at is the best possi

Note that for one workflow ID, it may be one or more workflow executions. You will call the Cancel Workflow Execution by ID for each one of them.

---

<div class="post-metadata">

**Author:** ![Bakhari](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/bakhari/32/29973_2.png) [@Bakhari](https://developer.sailpoint.com/discuss/u/Bakhari)\
**Post date:** [March 6, 2024, 7:48pm UTC](https://developer.sailpoint.com/discuss/t/need-to-update-workflow-when-certain-executions-are-still-in-running-state/24464/5 "2024-03-06T19:48:08Z")

</div>

I ran into this problem in my instance and THIS was the solution that helped me. Thanks!

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/sailpoint/original/2X/f/f2136700ed5e3703e0b85e02f6be799dacca7735.png) [@system](https://developer.sailpoint.com/discuss/u/system)\
**Post date:** [May 5, 2024, 7:48pm UTC](https://developer.sailpoint.com/discuss/t/need-to-update-workflow-when-certain-executions-are-still-in-running-state/24464/6 "2024-05-05T19:48:55Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
