Dear DQL Masters,
I have the following use case:
- I need to know all the entities that have a tag using DQL. For example I need to know all the entities, no matter if they are hosts, services, process groups, synthetics… and that contain a specific tag.
- I have created the following DQL:
fetch dt.entity.host
| fieldsAdd tags
| expand tags
| filter contains(toString(tags), “APP:TEST”)
| parse tags, “ld:key ‘:’ ld:tag_value”
| lookup [fetch dt.entity.service], lookupField: id, prefix:“lookup.affected.entity.services”
| lookup [fetch dt.entity.application], lookupField: id, prefix:“lookup.affected.entity.applications”
| lookup [fetch dt.entity.mobile_application], lookupField: id, prefix:“lookup.affected.entity.mobile”
| lookup [fetch dt.entity.custom_application], lookupField: id, prefix:“lookup.affected.entity.customapplication”
| lookup [fetch dt.entity.cloud_application], lookupField: id, prefix:“lookup.affected.entity.cloudapplication”
| lookup [fetch dt.entity.synthetic_test], lookupField: id, prefix:“lookup.affected.entity.synthetictest”
| lookup [fetch dt.entity.multiprotocol_monitor], lookupField: id, prefix:“lookup.affected.entity.multiprotocolmonitor”
| lookup [fetch dt.entity.custom_device], lookupField: id, prefix:“lookup.affected.entity.customdevices”
| lookup [fetch dt.entity.environment], lookupField: id, prefix:“lookup.affected.entity.environment”
But in the results it only shows me entities type hosts.
Is there any way to get all the entities that have this label using DQL?
Thanks a lot for your time
