This is what I’m attempting to achieve / configure in AF using Process Explorer. I realize that I could do so programmatically but that splits the configuration between (yet more) applications.
I’ve created a much dumbed-down example - xml attached. In practice there are many elements and many attributes of which a substantial number are PI Points and of these a significant fraction need to be handled in the way I describe.
The AF attribute [MyTag] contains a PI Point, the name and of configuration of which will be defined by either the client (organization) if it pre-exists or by the application if the PI Point is new. My solution for this up to know has been to create a AF table, Client_PI_Points, in which I define the PI Point name for a given element and attribute. In AF I construct a Default Tag based on %Element%.%Attribute. The AF attribute [Client Tag] uses a Table Lookup on Client_PI_Points to determine whether a client defined PI Point is to be used; if not then the [Default Tag] name is placed in [Client Tag]. The PI Point name itself, is placed into MyTag using substitution (which I am unable to paset here as the 'at' character is illegal!) .
The above works fine as did when I extended the above to include relevant items of the PI Point configuration in the AF Table. However, this configuration was applied regardless of whether The PI Point referenced in MyTag was [Client Tag] or [Default Tag]. The result being that a reset to template could (and has!) overwritten a PI Point configuration in the client’s PI system.
So how to make the configuration string specific to only [Default Tag] and to leave whatever is in the Pi system untouched if a client's PI Point is used? Simple…or so I thought; use String Builder to construct the Default Tag name from substation parameters and its configuration from values in child attributes (or another AF Table). Again, this worked but only up to the point of building a sensible [Default Tag] which is copied into [Client Tag]. However the substitution used in MyTag %@.|[Client Tag] resulted in double quotes being placed around the copied string rendering it invalid as a PI Point name For example Element1.MyTag ptclassname=classic; pointtype=float64 in [Client Tag] becomes “Element1.MyTag ptclassname=classic; pointtype=float64;” in [MyTag].
- Is there a way to suppress the double quotes?
- An alternative formulation within Process Explorer?
I include a copy of the very simple AF database as this seems easier than pasting lots of screen grabs.
PI Point Tests 1.xml.zip 1.4 KB