0
votes

I have a list called "Tasks"with a number column called "Count".

On the "Workflow Tasks" list, I have a workflow that gets triggered on item added or item changed. When a workflow task is created/edited, the workflow checks the status of the task and either adds 1 or minuses 1 to the "Tasks" "Count" column.

If I add a single task to the workflow task list, the workflow picks it up and adds 1 to the "Count" field perfectly. However, if i add two tasks to the workflow task list, one after the other, the second task's workflow results in an error.

It's almost like i'm unable to update the "Count" field multiple times. I assumed that the row was somehow "locked" while the first instance of the workflow was updating it, so I added a pause, which didn't help. (I guess because the 2 instances pause at the same time.) I then added another column to the "Tasks" list called "Busy" and set this to "Yes" while the first instance updated the row. When the second instance runs, it first checks if "Busy" is "Yes" and if so, it pauses for a duration and then carries on. This still does not work.

Is my assumption of row locking correct? Or what am I missing?

TIA!

Edit: I don't have access to the error logs and the error simply states "An error has occurred in [Workflow Name]".

1

1 Answers

0
votes

do you have many workflows and only one task to change? workflow runs, when task is changed or workflow list is changed?