Это должно работать для вас:
fields @message
| filter @message like /ABCD|BCDE|EFGH|IJKL/
| fields strcontains(@message, "ABCD") as @CONTAINS_ABCD,
strcontains(@message, "BCDE") as @CONTAINS_BCDE,
strcontains(@message, "EFGH") as @CONTAINS_EFGH,
strcontains(@message, "IJKL") as @CONTAINS_IJKL
| stats sum(@CONTAINS_ABCD) as @ABCD,
sum(@CONTAINS_BCDE) as @BCDE,
sum(@CONTAINS_EFGH) as @EFGH,
sum(@CONTAINS_IJKL) as @IJKL