grafana-zabbix icon indicating copy to clipboard operation
grafana-zabbix copied to clipboard

Add GROUP BY Function like influxDB or match item_value to application one to one

Open wangxin688 opened this issue 4 years ago • 1 comments

Hi Alex, I met this problem when using multiple variables in Function setAlias.
when I choose only one application(AP in pic), it's works fine, but if I choose multiple application(APs), the variable will be group by as a lists. I want to know if the application.item.value can be group with same application's other item. In zabbix discovery rule, the APChannel has different SNMP entry and {#SNMPINDEX}, so I can't use macro in item name to get this done. So I did this for improving the convenience of queries.

Here is my variable lists:

Group Zabbix-Group
Host Zabbix-Host
AP Zabbix-application
APChannel Zabbix-itemValues

as you can see with two pic.

  • works fine when choose one AP: image
  • could not match AP to it's APChannel one to one. image

With influxDB, it can be very easy to handle with GROUP BY and ALIAS BY image

So, is there any chance to support the same feature with the plugin? I think it's will avoid very complex sql query to

zabbix version: 5.2.0 DB: postgresql 12 with timescaleDB extended.

wangxin688 avatar Feb 05 '21 16:02 wangxin688