Asle Frantzen

Custom data reference to be used in naturally scheduled notification?

Discussion created by Asle Frantzen Champion on Mar 18, 2013
Latest reply on Mar 19, 2013 by Asle Frantzen

I've previously contacted techsupport because I couldn't get a PI Notification to start using naturally scheduling (event triggering) when the condition is an attribute based on a PI Point DR.




I think the help files say that the condition must be using an attribute which is a PI Point DR, or one which is based upon a PI Point DR. And I was indeed using a formula data reference, or other custom data references, which were based upon several PI Point DR's. But apparently this was not enough to get event triggering to work, and techsupport's understanding of "based upon a PI Point DR" was that the attribute would have to be a PI Point DR configured either as a direct or indirect reference (where indirect would mean that the PI Point DR pointed to another PI Point DR and got its values from that).


Now that differs from the other meaning of "an attribute which is a PI Point DR, or one which is based upon a PI Point DR", when we talk about which attributes can be shown as a trend in ProcessBook or other client tools. Here the idea is that if at least one of the attributes in a formula (or its parents/ancestors) has a data stream, you can trend it. So I automatically assumed the same thing would apply to event based triggering of PI Notifications.




So I'm a little bit stuck now. I have an attribute called "State" in my entire AF hierarchy, and for those attributes which are formulas based on PI Point DR's I've rewritten the notification templates to include a check for "AnyChange" in order to get event triggering. One "State" attribute which is a formula uses 12 tags, and in order to complete my notification template to check for "State=1" or "State=2" I have to have 12 AND-conditions for each state. I.e. "State=1 AND tag1 ANY CHANGE", "State=1 AND tag2 ANY CHANGE", "State=1 AND tag3 ANY CHANGE", "State=1 AND tag4 ANY CHANGE", etc.


But for the AF elements which are just structuring elements (like 'Region' and 'Substation') containing an unknown number of equipment elements I can't possibly manage to include a PI Point DR in the conditions. First of all, I can't reference attributes in child elements, from a notification template. And second, I don't know how many pieces of equipment belong to each 'Substation' - so I use the RollUp custom data reference. If I'd have to create a copy of the tag references in each and every 'Substation' I'd be stuck in front of the keyboard for a very long time.




So I guess my question in all of this would be if anyone has any experience with this? And if there is anything I can do code-wise to the RollUp data reference to allow notifications to trigger from new events occuring in any of the referenced children?