January 09, 2013

Workflow Status Values

When trying to filter based on a workflow status I need to know what the numeric value is behind the text.  I find this helpful when setting up views or site workflows for doing automated cleanup of old list items.

For example if I want filter for incomplete workflows I can filter WF Status Column not equal to 5.

This list of status Name/Value pairs is from MSDN:
0 - Not Started
1 - Failed on Start
2 - In Progress
3 - Error Occurred
4 - Canceled
5 - Completed
6 - Failed on Start (retrying)
7 - Error Occurred (retrying)
15 - Canceled
16 - Approved
17 - Rejected

I didn't see this on MSDN, but if a workflow has not been initiated on a list item the field content is Null.  Filter for "is/is not empty" if that's the case.  Also, this isn't a Nintex setting, but I use it all the time with Nintex workflows.