cancel
Showing results for 
Search instead for 
Did you mean: 

SAP MII - XMLtoJson converter - Single element to JSON array conversion

hipp_spja
Member
0 Kudos
223

Hi experts,

I try to convert a single XML element to a JSON array with the XmlToJson converter. Is it possbile to convert an single element to JSON array like this?

<root>
  <Array>
    <Item>MyValue<Item>
  </Array>
</root>

to this JSON

{
    "Array": ["MyValue"]
}

In the case that I more than one "Array" elements, the XmlToJson converter create a JSON Array, but in the case that I have just a single element it creates this here:

{
 "Array": "MyValue"
}

Is there a way the mark an XML element ro the XmlToJson converter, that it is part of an array?

Thanks for your help!

Regards,

Jan

Accepted Solutions (0)

Answers (0)