Creating Histogram with Multiple Series using Time Series Data in one Graph Panel

Hello,

I have the following query in postgres, and I would like to create a histogram with multiple series based on metric column

Query Template:
SELECT
value, – the value that I want histogram where y-axis is the occurrence and x-axis is the bins
metric, – the series
time
FROM
db

I am able to create the histogram by clicking the dropdown menu in the panel, however the only series I am seeing is count. Is there any way to make the metric the series?

Pull Request related to this issue for reference: https://github.com/grafana/grafana/pull/8613

Thank you for your help!