Skip to content
Advertisement

Creating tables in InfluxDB via Terminal

Are there tutorials online that teaches you how to create tables and input values in InfluxDB? How would you create a table and insert values into them?

Advertisement

Answer

InfluxDB doesn’t really have the concept of a table. Data is structured into series, which is composed of measurements, tags, and fields.

Measurements are like buckets.

Tags are indexed values.

Fields are the actual data.

Data is written into InfluxDB via line protocol. The structure of line protocol is as follows

An example of a point in line protocol:

To insert data into the database you’ll need to issue an HTTP POST request to the /write endpoint, specifying the db query parameter.

For example:

For more information see the Getting Started section of the InfluxDB docs.

User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement