ObjectID Mapping
- Last UpdatedNov 04, 2025
- 3 minute read
ObjectID Mapping, also known as Identification, determines the ID assigned to an object in the output. Each mapping entry in the configuration is examined in turn and the first matching entry is used to generate the object’s ObjectID.
The simplest form of ObjectID map entry to derive ObjectID for an object is shown below:
<Object>
<Conditions>
<Attribute name="object_class" pattern="Door" />
</Conditions>
<ObjectID value="[GlobalId]">
</ObjectID>
</Object>
Note: Conditions may hold multiple attribute elements. All conditions must be met for the mapping to be applied.
Lookups may be used to obtain the objectID from an external data source.
<Object>
<Conditions>
<Attribute name="object_class" pattern="Door" />
<Attribute name="Name" pattern="Door 100X40" />
</Conditions>
<ObjectID value="[GlobalId]">
<Lookup id="ExcelLookup" >
<FailAction action = "DiscardObject" />
</Lookup>
</ObjectID>
</Object>
In this case, the value of the GlobalId attribute is used as a key to look up a value for the ObjectID. If no match is found, value is derived from its fail action.
You can use Transforms to modify the value of an attribute, as shown below:
<Object>
...
<Conditions>
<Attribute name="object_class" pattern="Door" />
</Conditions>
<ObjectID value="[GlobalId]_[object_name]">
<Transforms>
<Keep pattern="pump-\d{2}[A-Z]" />
<InsertAfter pattern="^.*$" value="InsertAfter" />
<InsertBefore pattern="^.*$" value="InsertBefore " />
</Transforms>
</ObjectID>
...
</Object>
For example, if the initial ObjectID value is "3$pEhtFpv31QFndkpGikoC_this pump-01A is new", the final value after <Transforms> will be "InsertBeforepump-01AInsertAfter".
Attributes from associated objects can also be used to modify the value of ObjectID, as shown below:
<Object>
...
<IncludeAssociatedObjectAttributes type = ^FillsVoids$" refID = " [GlobalId] "/>
<Conditions>
<Attribute name = "ClassName" pattern = "^OPENINGELEMENT" />
<Attribute name = "Name" pattern = "^element1$" />
</Conditions>
</IncludeAssociatedObjectAttributes>
< ObjectID value="[#TEXT#]_[associated:#TEXT#]" />
...
</Object>
In this case above, the value of the GlobalId attribute along with the value of GlobalId of the first associated object matching the condition is used in deriving ObjectID.
Note: The prefix "associated:" is used when referring to the associated object's attribute.
If an object is not associated with an ObjectID, it is not included in the output. This provides a means of filtering out unwanted objects. To avoid this, an entry should be created at the bottom of the mapping file that matches any object. For example:
<Object>
<ObjectID value="[GlobalId]"/>
</Object>
Note: The log files indicate a warning message whenever multiple objects in the EIWM have a common ObjectID value. You can then decide if these objects must be unique, so that you must modify the relevant value in the source system or choose to use another method to determine the ObjectIDs.
The following example shows the warning message in the log file:
Object with [ObjectID]-[ClassID]-[Context]: "<ObjectID value>-<ClassID value>-<Context value>" is duplicated. Please revisit the mapping configuration.
Expand Interpolate:
The Expand feature lets you create multiple objects in the EIWM output from an attribute value containing text delimited with a separator (such as comma or semi-colon). You can use any number of Expands to build the tags incrementally. A separate object is created in the output for each expanded tag and the value is used as the ID of that object.
Note: The Expand mapping pattern must contain the expansion character to consider the attribute value for the expansion.
Examples:
<Object>
<Conditions>
<Attribute name="object_class" pattern="Door" />
</Conditions>
<ObjectID value="P-101A/D">
<Expand interpolate = "false">
<Pattern>[A-Z]/[A-Z]</Pattern>
<Char>-</Char>
</Expand>
</ObjectID>
</Object>
[A-Z]/[A-Z] in the above example helps create two tags named P- 101A and P-101D as the interpolate setting is set to false.
<Object>
<Conditions>
<Attribute name="object_class" pattern="Door"/>
</Conditions>
<ObjectID value="P-101A/D">
<Expand interpolate = "true">
<Pattern>[A-Z]/[A-Z]</Pattern>
<Char>-</Char>
</Expand>
</ObjectID>
</Object>
[A-Z]/[A-Z] in the above example helps create four tags named P- 101A, P- 101B, P- 101C and P-101D as the interpolate setting is set to true.
<Object>
<Conditions>
<Attribute name="object_class" pattern="Door"/>
</Conditions>
<ObjectID value="ABA-D1/3">
<Expand interpolate = "false">
<Pattern>[A-Z]-[A-Z]</Pattern>
<Char>-</Char>
</Expand>
<Expand interpolate = "true">
<Pattern>[0-9]/[0-9]</Pattern>
<Char>/</Char>
</Expand>
</ObjectID>
</Object>
In the above example, tags named "ABA1", "ABA2", "ABA3", "ABD1", "ABD2" and "ABD3" are created. The first Expand block creates the following tags "ABA1/3" and "ABD1/3". The second Expand block further splits tags "ABA1/3" into "ABA1", "ABA2" and "ABA3" and "ABD1/3" into "ABD1", "ABD2" and "ABD3". Finally, six tags named "ABA1", "ABA2", "ABA3", "ABD1", "ABD2" and "ABD3" are created.