Start date for Monthly line chart

  • What Grafana version and what operating system are you using?

  • What are you trying to achieve?
    Create a in Time Series chart for data grouped over Months

  count(number) AS "number"
FROM incident
ORDER BY $__timeGroup(time,1M)
  • How are you trying to achieve it?
    My data is in MYSQL and I am creating line chart using MySQL query

  • What happened?
    Start of the month is shown as some Random date rather than 1st of month in Time Series chart.

  • What did you expect to happen?
    Start of the month should be 1st of month

  • Help I need?
    Is there way I can have Start of the Month in Time Series chart?

Here is snapshot where it shows 14th as start of month rather than 1st.

Hi @kapilkathuria,

Welcome to the :grafana: community forum !!

It seems to be more related to the SQL query which needs to be defined correctly so that it can show the months in the correct sequence.

Please follow the following reference links as it might be helpful to get your desired result.


The best way will be to first execute your query inside the MySQL shell to see if it gives you the desired result and then use the Grafana->Exploer and there build your query by using the “Edit SQL” and then put the values there (either in the template or your own custom way),

Hope it helps