Today I encountered a list item that had two instances of the same workflow, both stuck on the first step.
“End this workflow” – 0
“Suspend this workflow – 0
Workflow Instances – 4
Having encountered this cockroach of workflows, to PowerShell I went. Hoping that I would be able to terminate the workflow instances.
PowerShell – 0
Workflow Instances – 6
No matter what I tried, the score kept increasing, and not in my favor.
After working on this all morning, I finally hit “F#(< it” mode and cracked open SQL Management Studio. I expanded the WFInstanceManagementDB > Tables > dbo.Instances and did the unthinkable. “Edit Top 200 Rows”, yes I directly edited the database. I’m crazy like that.
Mousing over the workflow instance on the Items Workflows page will list the Workflow Instance ID at the end of the URL in the bottom of the browser window. Match that in the InstanceId column of the sdo.Instances table and scroll to the right to the WorkflowStatus column. Change the status to Terminated and hit Enter to update.
Back to SharePoint and F5 the workflows page.
Workflows – 6
SharePoint Sheriff – 1 (the one that counts)
*mouse drop* <– like a mic drop but geekier