Skip to content

Influxdb tags with forward slashes '/' break grafana #6012

@Ismael

Description

@Ismael
  • I'm submitting a ...
  • Bug report

Please include this information:

  • What Grafana version are you using?
    3.1.1
  • What datasource are you using?
    InfluxDB 0.13
  • What OS are you running grafana on?
    Linux
  • What did you do?
    Build a query with a tag that includes forward slashes
  • What was the expected result?
    Graph!
  • What happened instead?
    InfluxDB says the query is invalid. Plus sign in query editor no longer works.

Query is:
SELECT mean("resp_time") FROM "test" WHERE "url_class" =~ /web/start/ AND time > now() - 5m GROUP BY time(200ms) fill(null)

plusbroken

When I press +, the following query is issued:
SHOW TAG KEYS FROM "test" WHERE "url_class" =~ /web/start/

And I get 400 error:
{"error":"error parsing query: found start, expected ; at line 1, char 53"}

I guess the error is in not escaping the '/'.
This query works: SHOW TAG KEYS FROM "test" WHERE "url_class" =~ //web/start//;

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions