skip to Main Content

Mysql – Improving performance of SQL query for time series data

I'm writing a query in MySQL for a Grafana dashboard, but the performance of only this particular query is very poor. This is the query: SELECT br.reading ,CONCAT(ino.project,"_",SUBSTRING_INDEX(br.sensor,"_",-1)) AS new_metric ,ino.vessel ,ADDTIME(DATE('2023-01-01'),-TIMEDIFF(ino.date,br.datetime)) AS norm_date ,br.sensor FROM db.milestones br INNER JOIN…

VIEW QUESTION
Back To Top
Search