I would like create a single KPI that uses a conditional count. This KPI should display the count of the number of cases within a process that has a duration < 60 days between two specific events.
Page 1 / 1
Hello,
Â
I think this one should solve the problem, please note that I've used Last to First occurrence reference - you can specify 3 options for that:
Â
- FIRST_OCCURRENCEC'activity']: Throughput time starts at the first occurrence of the specified activity type.
- LAST_OCCURRENCEC'activity']: Throughput time starts at the last occurrence of the specified activity type.
- CASE_START: Throughput time starts at the first activity of the case.
Â
PQL:
Â
SUM (
   CASE WHEN CALC_THROUGHPUT (
       LAST_OCCURRENCE S 'Activity1' ]
       TO
       FIRST_OCCURRENCE 'Activity2' ] ,
       REMAP_TIMESTAMPS ( "ACTIVITIES"."EVENTTIME" , DAYS )
   ) < 60 THEN 1.0 ELSE 0.0 END)
Â
In order to have a ratio you probably need to replace SUM() with AVG().
Â
Best Regards,
Mateusz Dudek
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.