Count Running and Stopped Services Using DQL Queries (Dynatrace 3rd gen)

I need the count of running services and stopped services against each management zones in dynatrace dashboard(gen3). Below dql is not working

fetch dt.entity.os_service, dt.entity.host
| lookup dt.entity.host, from: runsOn, sourceField: id
| fieldsAdd mz = entityAttr(dt.entity.host, “managementZones”)
| filter isNotNull(mz)
| expand dt.osservice.availability
| summarize running_services = countIf(value == 1), stopped_services = countIf(value == 0), total_services = count() by: entity.name, mz
| sort mz asc

Hey @donaannie1 ,
I just wanted to check in and see if you still need help with this. If so, I’d be happy to look into it for you! :blush:
Please let me know what works best for you.