Creating a measurement with two separate columns in influxdb

Hello guys , I'm kind new to NodeRed, so pardon me if this question seems obvious.
I'm pushing data from many sensors to a mosquitto broker. This data is stored in an influxDB database. This is my NodeRed flow and debug message like:


Capture2
Now, i want to create a new measurement "table" in InfluxDB with voltage and current in two separate columns "in the same measurement", how can this be achieved?!

It is not clear if you are recreating a measurement (table) for each temp/current in Influxdb.
There would been reason to do so. A better way is to eventually create one table for each sensor simply connecting one influxDB node directly to the output of your JSON node.

The usual way to record data like that would be to put the temperature data from all sensors into one measurement, with the temperature as a field and the id as a tag, to put all the voltage/current data into another measurement with voltage and current as fields, and the id as a tag, and to put the illuminance data into a third measurement, in the same way.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.