Question & Answer
Question
XMLEncoder service: How to access nodes with a default name space using XPATH expressions *|* -6D0E62A6A7609B41852579170042B9DF- *|*
Answer
Technote (FAQ)
Question
XMLEncoder service: How to access nodes with a default name space using XPATH expressions
Answer
The XMLEncoder service is used to transfer nodes from the input xml document into the process data. The xml document has?a default name space specified.
In this case you have to use the local-name function. Additionally the inmsg node has to be specified explicitly - the // notation does not work in this case.
Example
<root xmlns="http//www.test.de">
<node1> text </node1>
<node2>text2</node2>
</root>
XMLEncoder configuration:
? <operation name="XML Encoder Extrahiere Filterdaten">
????? <participant name="XMLEncoder"/>
????? <output message="XMLEncoderTypeInputMessage">
??????? <assign to="mode">xml_to_process_data</assign>
??????? <assign to="output_to_process_data">YES</assign>
??????? <assign to="." from="*"></assign>
????? </output>
????? <input message="inmsg">
??????? <assign to="Node1" from="/inmsg/*[local-name()='node1']/text()"></assign>
????? </input>
??? </operation>
| Segment | Product | Component | Platform | Version | Edition |
|---|---|---|---|---|---|
| Commerce | Sterling B2B Integrator | Adapters |
Historical Number
FAQ2275
Was this topic helpful?
Document Information
Modified date:
12 October 2021
UID
ibm10767621