Forum Discussion
RRaj_293
1 year agoHelper III
Count distinct field based on process Sequence
Hello , I want to count the distinct IDs which have completed the process cycle which is from 'New Email' to 'Complete' only. Other IDs with an incomplete process cycle which does not End wit...
- Anonymous1 year ago
Hi RRaj_293 ,
I have tested Selva-Salimi's workaround, it will return a error due to GroupBY.
I think you can try code as below to create a measure.
CompletedCycleIDs = VAR _FILTER = FILTER(ProcessData,ProcessData[Process Status] IN {"NEW EMAIL","COMPLETE"}) VAR _SUMMARIZE = SUMMARIZE(_FILTER,[ID],"COUNT", VAR _ID = [ID] RETURN COUNTAX(FILTER(_FILTER,[ID] = _ID),[ID])) RETURN COUNTX(FILTER(_SUMMARIZE,[COUNT] = 2),[ID])Result is as below.
Best Regards,
Rico ZhouIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
1 year agoNot applicable
Hi RRaj_293 ,
I have tested Selva-Salimi's workaround, it will return a error due to GroupBY.
I think you can try code as below to create a measure.
CompletedCycleIDs =
VAR _FILTER = FILTER(ProcessData,ProcessData[Process Status] IN {"NEW EMAIL","COMPLETE"})
VAR _SUMMARIZE = SUMMARIZE(_FILTER,[ID],"COUNT",
VAR _ID = [ID]
RETURN
COUNTAX(FILTER(_FILTER,[ID] = _ID),[ID]))
RETURN
COUNTX(FILTER(_SUMMARIZE,[COUNT] = 2),[ID])
Result is as below.
Best Regards,
Rico Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.