Skip to content

Instantly share code, notes, and snippets.

@ruanbekker
Created April 14, 2019 20:46
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 ruanbekker/68a6307cabe7fa21bff54ab2822b3f55 to your computer and use it in GitHub Desktop.
Save ruanbekker/68a6307cabe7fa21bff54ab2822b3f55 to your computer and use it in GitHub Desktop.
InfluxDB Queries

Write to InfluxDB:

$ curl  -i -XPOST "http://influxdb:8086/write?db=foo" \
  --data-binary 'events2 title="my-title",text="test-text",tags="my-tags",woof=true'

InfluxDB Queries:

> use foo
Using database foo
> show measurements
name: measurements
name
----
events
events2
> select * from events2;
name: events2
time                tags    text      title    woof
----                ----    ----      -----    ----
1555274509682249767 my-tags test-text my-title
1555274636266821261 my-tags test-text my-title true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment