You are not logged in.
Pages: 1
Good morning, I would like to know if I could make a query in MySQL to compare the number of tickets by year and by month. The idea is to transfer the mysql to GRAFANA.
https://blogger.googleusercontent.com/i … s640/1.png
It would be like this graph but you would need the MYSQL code.
Last edited by sebastianxxx (2024-06-28 15:31:43)
Offline
select year(ti.date) as 'year',month(ti.date) as 'month', count(ti.id) as 'count'
from glpi_tickets as ti
where ti.date>'2023-01-01'
group by year,month
Trouver la panne avant de réparer...
GLPI10.0.16 (ubuntu 22.04 PHP8.1 Mariadb10.6 ) plugins : comportements 2.7.3 reports 1.16.0 formcreator 2.13.9, datainjection 2.13.5 fields 1.21.9
Offline
select year(ti.date) as 'year',month(ti.date) as 'month', count(ti.id) as 'count' from glpi_tickets as ti where ti.date>'2023-01-01' group by year,month
Thank you very much friend, the query is perfect, but in GRAFANA I am doing something wrong and it is not working for me. Anyway, I thank you very much for your help.
Offline
Pages: 1