Doesnt look exactly like what you're looking for but if taken to a pivot this could be done:
index="summary" source="a.txt"
|rex field=_raw "(?<service_number>(?<=Service).*(?==[1|0] ))"
|rex field=_raw "(?<running>(?<=Service..=)([0|1]))"
|eval running=if(running==1,"Running","Stopped)
|eval serviceName=if(match(service_number,"\d1"),"Service 1",if(match(service_number,"\d2"),"Service 2",if(match(service_number,"\d3"),"Service 3",if(match(service_number,"\d4"),"Service 4",if(match(service_number,"\d5"),"Service 5","n/a")))))
|stats first(running) as Status by serviceName, host
... View more