Data for groovy script in complex datapoint

  • 23 March 2023
  • 2 replies



I have a question regarding using data in complex datapoint.
Long story short - I need to use base-10 logarithm for some calculation - in complex datapoint I can use only log function so my idea is to use groovy script and then I can use Math.log10

DS is using SCRIPT for discovery method and another groovy script is collecting attributes/data.
I would like to use data which is displayed in Normal datapoints (##WILDVALUE##.something).

Is there any smart way to process/get that data in complex datapoint groovy script ? (without pooling device again as it is already done in "Collector Attributes")

2 replies

Userlevel 7
Badge +17

I don’t think so. I think you’d have to pull the normal datapoints into your script, perform the same math again, then you’d have the value available to use in the rest of the script. 

My theory is that the groovy complex datapoints are calculated in the same stage as the rest of the complex datapoints. Meaning, the complex datapoint values haven’t been calculated by the time the groovy complex datapoint would need them.


Thanks Stuart - now at least I know in which direction should I go 😄