Hi all,
We need a Mysql query to obtain which triggers are associated with each host but can¡t find any relation on the database model to obtain it.
My first approach is:
select i.description
from zabbix.triggers i
(select h.hostid, h.host
from zabbix.groups g, zabbix.hosts_groups hg, zabbix.hosts h
where g.groupid = hg.groupid
and hg.hostid = h.hostid
and g.name='New_hosts') H
where i.hostid = H.hostid;
But unfortunality it doesn't works cause there's no relation between hosts and triggers on my query.
Any help?
Thanks!
We need a Mysql query to obtain which triggers are associated with each host but can¡t find any relation on the database model to obtain it.
My first approach is:
select i.description
from zabbix.triggers i
(select h.hostid, h.host
from zabbix.groups g, zabbix.hosts_groups hg, zabbix.hosts h
where g.groupid = hg.groupid
and hg.hostid = h.hostid
and g.name='New_hosts') H
where i.hostid = H.hostid;
But unfortunality it doesn't works cause there's no relation between hosts and triggers on my query.
Any help?
Thanks!


:
Comment