How to identify the date of a returned value?
-
This returns a (CW.past(MINUTE,backcounter).maximumValue) correctly...
I would like to know how to examine the timestamp on this pointvalue? -
Hi Phillip,
Have a look at the
.maximumTime
property, https://help.infiniteautomation.com/about-mango-java-script/ -
thanks got it
-
Phil I am trying to use the new functionality of the meta recalculation. purge a timeperiod and recalc. I recall you saying the script process will now log an entry when it finishes, is this in 3.3 now?
I am trying to recalc a 1 day period and I check purge the data beforehand.
but the process seems to hang even on a short 1 day meta recalculation
with this script; It runs fine in simulation mode... any ideas what could be causing this?var LITERS_LAST_5MIN;
if (CW.past(MINUTE,5).delta === Number.NaN){
LITERS_LAST_5MIN = 0;
} else {
LITERS_LAST_5MIN = CW.past(MINUTE,5).delta;
}
return LITERS_LAST_5MIN; -
Yes, debug log messages were added for completion and checked exceptions. If there is a Logger in your Mango/classes/log4j2.xml for
com.serotonin.m2m2.meta.MetaEditDwr (or one of the parent packages). at debug level? Try adding this below the other <Logger/> tags and reloading your Log4J configuration on in the Log4J Reset section of the system settings.<Logger name=" com.serotonin.m2m2.meta.MetaEditDwr" level="debug"/>
Edit: No offhand I don't know what's going on there. You may be able to see the point values have been deleted, and then you can watch them regenerate.
-
something screwy about this new history purge feature. I made a mistake entering the end date when I ran the first time and it created records back to 1969.