afaik you can’t do that, the time column can’t be specified or overridden in general unless the input you use has some settings for it.
Since you are parsing JSON data, I’d like to know which is the input plugin, because if it allows you to choose the data format (JSON in this case) then you should be able to achieve that as the Telegraf Json parser allows you to specify where to take the timestamp in its settings json_time_key, json_time_format, json_timezone
I’m not sure about the time format, the string looks ok and a simple “2020-10-26T15:20:42.06126” might work, the examples limit themselves at seconds precision tho, so I’m not sure about the milliseconds, just have a look at what can be passed (you will find all in the telegraf and GO docs, start from quote above)
Hello Giovanni
.
Thank you for your precious help. It works now, I have the timestamp of the gateway that goes back in the data key. Thanks again !!
.
Here is the exact configuration of the plugin [[inputs.mqtt_consumer]], it will help those who ask this question: