Legend names for graphs appear double

I’m not sure if I’m doing something wrong or if this is a bug. My searching didn’t helped me a whole lot, so therefore I ask here:

I am reading my data off a SQLite database with the sqlite plugin for grafana. When creating a time series by default the legend for the graphs is the same as the column name.

I want to have a different name so I inserted an alias selector in the query. However, now the legend names appear doubled.

What am I doing wrong?

I just noticed, the double names already start coming up if I only use the alias operator on the one query…
(can’t share the screenshot due to limitations)

Additionally I just noticed that this behaviour only happens while I have two query running for the same plot. If I remove one of them I goes back to the desired behaviour.
Can it be connected to the fact that both columns are called “value”? But then I would assume something like “alias1 alias2” to happen. I’m confused.

I generally adjust the display names of columns through the Grafana visualization configuration instead of using the query. Have you tried that?


I have this exact problem and I have spent 6 hours in forums trying to find what I have done wrong thinking it was my query that was wrong.

I have finally found out what to do. I was getting … ’ Electricity Electricity ’


For anyone having the same problem, here is what you do



Firstly frser I want to thank you for making SQlite add-on :grinning:

But if there is an easy fix in your add-on, could it be made, as it has taken most of my day to resolve it and I am new to Grafana.

Thanks for the add-on I appreciate your time and effort :+1:

Thanks Gaz

That is a good point actually. With the multiple questions and weird behavior around that I opened an issue in the Github repo: Legend appears twice · Issue #96 · fr-ser/grafana-sqlite-datasource · GitHub

I’ll follow up on this issue there (and at least I will add some information to the FAQ in case I cannot get rid of that behavior)


You shouldn’t have to add an “override” but just use the regular “display name” setting.
This works pretty well in my opinion.

The version 3.1.1 of the plugin will have a bit better naming here but the core issue of more information added to the legend is due to Grafana (especially if using multiple lines in a chart).

Some more information can also be found here: Legend appears twice · Issue #96 · fr-ser/grafana-sqlite-datasource · GitHub