Hi,
I am trying to create monitoring for MySQL query
I create template and in Discovery add discovery rule as
Database monitor
key: db.odbc.discovery[daily_sales,db_qa_masqa_3306]
query
select term_no as TERMNO ,sum(amount) as AMOUNT from p_trx where trx_date > curdate() group by term_no
Query is good, and it retrieves a record from DB like
{"data":[{"{#TERMNO}":"3001","{#AMOUNT}":"10265"},{"{#TERMN O}":"3002","{#AMOUNT}":"525"}]}"
Now I have a problem setup Item prototypes
In name I add
Daily sales term {#TERMNO} - {#AMOUNT}
and I see both values are available for the item but I don't know how to setup type and key that AMOUNT will be listed as latest value for key #TERMNO.
Thank you for suggestions.
----
Zabbix version 3.4.6 ( not 3.4.5 as in the title)
I am trying to create monitoring for MySQL query
I create template and in Discovery add discovery rule as
Database monitor
key: db.odbc.discovery[daily_sales,db_qa_masqa_3306]
query
select term_no as TERMNO ,sum(amount) as AMOUNT from p_trx where trx_date > curdate() group by term_no
Query is good, and it retrieves a record from DB like
{"data":[{"{#TERMNO}":"3001","{#AMOUNT}":"10265"},{"{#TERMN O}":"3002","{#AMOUNT}":"525"}]}"
Now I have a problem setup Item prototypes
In name I add
Daily sales term {#TERMNO} - {#AMOUNT}
and I see both values are available for the item but I don't know how to setup type and key that AMOUNT will be listed as latest value for key #TERMNO.
Thank you for suggestions.
----
Zabbix version 3.4.6 ( not 3.4.5 as in the title)
Comment