How to apply math to values before storage?

Hi.

I want to multiplicate some values by 3 before storage in the database.
How do I do that?

/Peter

Hello @pettaflex,
What type of data you’re collecting and how are you collecting it?

Without more information, I can tell you these options:

  • Use the exec plugin.
  • Use a client to write the points and do whatever processing you want.
  • Create an aggregator plugin similar to basicstats plugin.

The data is just a “1” from some energy meters.
But I am too cheap to measure all 3 fases and need to multiply the data with 3 to get total consumption.
I know that won’t give the completely accurate measurement but I have a very large consumption and the majority is on all 3 fases!
I use telegraf via mqtt