Equipment Templates: Outputs
- Last UpdatedJul 18, 2023
- 2 minute read
The template (XML) file can contain 1 or more output sections that define the configuration records that are to be created in other database (DBF) files. The output nodes are defined within the template node and contain the list of database fields that are to be updated in the new record. An Equipment Templates: Output Node should be added for each record that is to be created, such as a variable tag, alarm, trend, etc.
The values specified for each of the Equipment Templates: Output Field elements will be written to the database (DBF) field of the output file. Values from input fields and parameter strings can be referenced within this section to construct the resulting value for the output record field. Each output node should have a unique output name specified across the records in the template.
Refer to the following available output databases section for specific details on each of the available output databases and other advanced topics.
The example below shows a sample for an output to the variable database (DBF). For each output section, the field names specified should include the Equipment Templates: Output Common Fields and the fields specific to each Output Database.
To use the example below, replace the following in your template:
-
[FileRef] with a short string reference for the output destination database. Such as 'Var', 'Trend', 'AlmDig', 'Menu', etc. Examples are provided with the list of available databases
-
[RefID] with a unique index (1, 2, 3, etc.) or a related string value for the entry (such as ON, STOP, etc.) for the specific output record.
-
[TypeRef] with the abbreviation of the type name as defined in the parameter section. This may need to be an abbreviation of the full type name as the total length of [TypeRef].[RefID] should be 32 chars or less to fit the 'taggenlink' field.
Example
<!-- ===================================================
Output Section - <my variable tag>
===================================================
-->
<output name="[FileRef].[RefID]" file="variable.dbf" filter="'{equipment.type}={type.name}'">
<field name="taggenlink" load="true">[TypeRef].[RefID]</field>
<field name="linked">1</field>
<field name="editcode">11</field>
<field name="name" key="true">{equipment.tagprefix}[Tag Suffix]</field>
<field name="type">[Tag Data Type]</field>
<field name="unit">{equipment.iodevice_list[0]}</field>
<field name="addr">[Tag Address]</field>
<field name="comment">[Tag Comment]</field>
</output>