Removing of bad DCI data

Started by aalexson, January 22, 2017, 05:35:54 PM

Previous topic - Next topic

aalexson

When setting up different nodes for capturing data (Raspberry Pi and temperature probes), at times when pulling for data when rewiring the Raspberry Pi (adding another temp sensor), the returned value is 99.0. 

How does one remove some bad data?

Thank you.

Tursiops

I'd use a transformation script to filter out the known bad values.

Something like
if ($1 == 99.0) return null;
else return $1;


The above would replace the 99.0 with null. Technically still "bad data" and I admit I did not test using null (I tend to set "0" or some descriptive error, depending on what I'm collecting).

To remove data already collected, you either have to either clear the collected data (which will wipe your good data along with it) or go into your database, locate the bad values and remove them.

Hope this helps.

tomaskir

Returning 'null' from data collection will cause a data collection error.
The DCI will have '<<ERROR>>' value in 'Last Values', and nothing will be written to the DB.