on 02-11-2019 3:15 PM
We are using the XML-JSON conversion table to identify XML elements as Array.
Unfortunately, we have an element that appears as both Array and non-Array (under a different node). When we specify an element as Array, all occurances of that element is sent as an Array. Is there any way in conversion table to differentiate the element based on their parent node ?
Hi,
If Array Type is not maintained in Custom XML/JSON Conversion Rules and the XML element only occurs once, the XML element will be converted into a non-array-type. If Array Type is maintained in Custom XML/JSON Conversion Rules, the XML element should always result in a JSON array type even if the element occurs only once. If the XML element occurs more than once, it should result in a JSON array type. For more explanation, you can refer to:
SAP KBA 2743939 - XML Payload to JSON Conversion in REST receiver adapter
REST Adapter in PI/PO: Enhanced XML/JSON Conversion
Best regards,
Tina
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
If xml is well formatted then try converting it to Json with any third party tool.
Uncheck convert xml payload to json option in receiver channel or if synchronous scenario then in sender channel and deploy Custom_AF_Modules/FormatConversionBean module and check jsoncontent.
Regards,
Samir
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
share your xml structure if possible.
Regards,
Samir
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.