Skip to content

Instantly share code, notes, and snippets.

@influxdatamarketing
Created November 9, 2022 16:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save influxdatamarketing/fd0a2806224707f12cb0bc25586dfb1f to your computer and use it in GitHub Desktop.
Save influxdatamarketing/fd0a2806224707f12cb0bc25586dfb1f to your computer and use it in GitHub Desktop.
from(bucket: "syslog")
|> range(start: v.timeRangeStart, stop: v.timeRangeStop)
|> filter(fn: (r) => r["_measurement"] == "influxdb2.local0.debug")
|> filter(fn: (r) => r["_field"] == "facility" or r["_field"] == "host" or r["_field"] == "severity")
|> unique()
|> yield(name: "unique")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment