How Do I Unify Data Elements? (Magic xpi 4.13)
To unify multi-occurrence data elements into a single data element, use the Compound Level Computation mechanism. This updates a variable, while iterating the Source compound, to create the unified Destination data.
A temporary variable (F.Var1) should be used to accumulate Source data.
Sample Schema:
To unify data elements:
-
Drag a Data Mapper utility to the flow area.
-
From the Toolbox's Mapper Schemas section, drag an XML type into the Source area of the Data Mapper window.
-
In the XML Source's Properties pane, select the sample XML document.
-
From the Toolbox's Mapper Schemas section, drag a Variable type into the Destination area of the Data Mapper window.
-
In the Variable Destination's Properties pane, select C.UserString as the dummy variable in order to allow the iteration.
-
Map a repeatable simple element Source compound to the Instance Destination, as shown below. In the Destination’s Properties pane's Multi Updates parameter, click to open the Multi Updates dialog box to update an Alpha variable (F.Var1) with the value of the simple element Source data. For example:
F.Var1 & ' ' & Src.S1/Root/lines/Line