MSSQL Analyses related to processes


Process-Related

This article offers examples for instance and definition related analyses with the dashboard.


Instance-Related

Number of started instances per month

SELECT concat(DATEPART(yy, inst.creationTime),'-', DATEPART(mm, inst.creationTime)) AS Month, SUM(1) AS Count FROM view_instance inst GROUP BY concat(DATEPART(yy, inst.creationTime), '-', DATEPART(mm, inst.creationTime))

 

Average number of started instances per day per month (22 working days a month)

SELECT concat(DATEPART(yy, inst.creationTime),'-', DATEPART(mm, inst.creationTime)) AS Month, ROUND(SUM(1)/22,1) AS "Average per day" FROM view_instance inst GROUP BY concat(DATEPART(yy, inst.creationTime), '-', DATEPART(mm, inst.creationTime))

 

Number of started and completed instances for each definition

SELECT inst1.definitionname AS Prozess, COUNT(DISTINCT(inst1.id)) AS 'Number of started instances', COUNT(DISTINCT(inst2.id)) AS 'Number of completed instances' FROM view_instance inst1 LEFT JOIN view_instance inst2 ON inst1.id=inst2.id AND inst2.instanceEnd IS NOT NULL INNER JOIN view_activity act ON act.instanceid=inst1.id GROUP BY inst1.definitionname;​

 

Number of started, completed, aborted and running instances for each process definition

 

Activities, tasks and assigned users of running instances

 

Average cycle time (in h) of all instances of all process definitions per month

 

Number of started instances per month (columns) per year (rows) for a definition

 

Cumulative number of started instances per month (columns) per year (rows) for a definition

 

Minimum, maximum and average cycle time (in h) of instances per process definition

 


Definitions-Related

Number of loops (>0) per definition