I am making grafana dashboard using flux langauge. I need help in below tag queries

SHOW TAG VALUES FROM “jmeter” WITH KEY = “application”

SHOW TAG VALUES FROM “jmeter” WITH KEY = “transaction” WHERE “application” =~ /^$application$/ AND “transaction” != ‘internal’ AND “transaction” != ‘all’

@Sangeeta_Agarwal The first query is pretty simple in Flux. There is a function specifically for this and it should be pretty quick depending on what version of InfluxDB you’re using. Because the 2nd query conditionally checks for tag values, it can’t use the same function. Here’s what the two queries would look like:

import "schema"

schema.measurementTagValues(
    bucket: "example-bucket",
    measurement: "jmeter",
    tag: "application",
    start: -30d,
)
import "regexp"

from(bucket: "example-bucket")
    |> range(start: -30d)
    |> filter(fn: (r) => r._measurement == "jmeter")
    |> filter(fn: (r) => exists r.transaction and r.transaction != "internal" and r.transaction != "all")
    |> filter(fn: (r) => r.application == regexp.compile(v: "^${application}$"))
    |> distinct(column: "transaction")

Thank you Scott.
It worked :):