I've been using an If condition in IIB Mapping node on request's boolean attribute Flag that maps to messageA attribute in response. Assignment is done in case Flag evaluates as true.
There is another For Each which performs deep copy of a list and also assigns some value to the same variable messageA, if Flag is evaluated as false.
Below is the Mapper Logic:
The above logic yields valid XML in case Flag is false, but in case of true it assigns the value successfully, however invalidates the response as defined in the XSD, by appending messageA attribute as the last child of response XML.
How can the second scenario be treated? Considering no custom ESQL logic in the latter nodes.
