Skip to main content
Nintex Community Menu Bar

Find all Workflows in farm by last run date

  • Jul 12, 2019 3:25 PM UTC
  • 4 replies
  • 391 views
  • Translate All

Forum|alt.badge.img+1

Need to know which workflows are active in our farm(s), run in the last xx days. Ideally, a report listing each workflow, the collection and site it lives in, the workflow name, and last date run. I see lots of powershell to list workflows but do not see any to get last date run. 

4 replies

Simon Muntz
Nintex Partner
Forum|alt.badge.img+23
  • Nintex Partner
  • Jul 15, 2019 12:53 AM UTC

Hi,

You could run a query on your content databases to get this information.

Select WorkflowName,MAX ([StartTime]) AS 'Last Started', SiteID, ListID, WebID
From dbo.WorkflowInstance
Group By WorkflowName, SiteID, ListID, WebID
Translate

Forum|alt.badge.img+9
  • Jul 15, 2019 10:52 AM UTC

see Know your workflows

Translate

Forum|alt.badge.img+1
  • Author
  • Jul 23, 2019 12:44 PM UTC

Thanks for the script. Do we know if this script collects all workflows, list and site, associated with a particular database? 

Translate

Simon Muntz
Nintex Partner
Forum|alt.badge.img+23
  • Nintex Partner
  • Jul 29, 2019 10:38 PM UTC
Hi,
The script I have provided is per database.
The script provided by mlauer will show every workflow in the environemnt from all databases.
Translate