Skip to main content

Hello everyone,

i was wondering whether CALC_CROP functions with PU_FIRST or PU_LAST.

what I want is to count a number of specific activities between the process start to one of the other activities (whichever of them comes first);

so i would like to use smth like

PU_COUNT(

CASES, ACTIVITIES.ACTIVITY,

ACTIVITIES.ACTIVITY IN (A,B,C,D) AND

CALC_CROP(CASE_START TO PU_FIRST(CASES,ACTIVITIES.ACTIVITY, ACTIVITIES.ACTIVITY IN (E;F;G)), ACTIVITIES.ACTIVITY)=1)

)

however it doesnt work. Any ideas?

Best,

Maria

Hi Maria,

I dont think a PU function works inside the CROP function. However, you could count the number of cases that start with specific activities using the PROCESS ORDER function like:

PU_COUNT(
"CASES", "ACTIVITIES"."ACTIVITY",
"ACTIVITIES"."ACTIVITY" IN (A,B,C,D) AND
PU_FIRST("CASES",PROCESS_ORDER("ACTIVITIES"."ACTIVITY"),"ACTIVITIES"."ACTIVITY" IN (E;F;G))=1
)

Best,

Viana


Reply