From 8efb3fb7d8a2ee489839a953ecc515bc17e587a5 Mon Sep 17 00:00:00 2001 From: Philip O'Toole Date: Tue, 1 Sep 2015 20:08:01 -0700 Subject: [PATCH] Use Measurement name, not a column "name" This results in proper Measurement output. --- monitor/service.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/monitor/service.go b/monitor/service.go index 26381e0698..a34c5843ac 100644 --- a/monitor/service.go +++ b/monitor/service.go @@ -125,12 +125,9 @@ func (s *Service) executeShowStatistics(q *influxql.ShowStatsStatement) *influxq rows := make([]*influxql.Row, len(stats)) for n, stat := range stats { - row := &influxql.Row{} + row := &influxql.Row{Name: stat.Name} values := make([]interface{}, 0, len(stat.Tags)+len(stat.Values)) - row.Columns = append(row.Columns, "name") - values = append(values, stat.Name) - for _, k := range stat.tagNames() { row.Columns = append(row.Columns, k) values = append(values, stat.Tags[k])