Reads values from an XML column and converts them into JSON format.
- If there are multiple pieces of text around inner elements, they are translated into elements of a JSON array.
- Text content inside XML elements is stored under a specified key (default key is
text). - If enabled, XML attributes are converted to JSON keys with an
@prefix. - If enabled, XML processing instructions are converted to JSON keys with a
?prefix.
The XML
<a>Hello <b>world</b>!</a>
becomes:
{
"a": [
"Hello ",
{
"b": {
"text": "world"
}
},
"!"
]
}