|
|
1
5
首先,请记住XML和JSON结构不是1:1兼容的。
这个
在您的示例中,JSON根对象的第一个元素被用作XML文档的根。您可以通过用假根对象包装输入JSON来解决此问题: {
"root": {
"site": "mysite",
"erpCustno": "123",
"shipToState": "PA",
"shipToZip": "16684",
"lineInfo": [
{
"lineNumber": "10",
"product": "MAT203"
}
]
}
}
但您可能仍然存在
|
|
|
2
0
正如david所说,它需要一个格式正确的json,mule可以完美地转换它。我已经分享了流程细节。 流
http://www.springframework.org/schema/beans/spring-beans-current.xsd http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd http://www.mulesoft.org/schema/mule/json http://www.mulesoft.org/schema/mule/json/current/mule-json.xsd http://www.mulesoft.org/schema/mule/jms http://www.mulesoft.org/schema/mule/jms/current/mule-jms.xsd http://www.mulesoft.org/schema/mule/file http://www.mulesoft.org/schema/mule/file/current/mule-file.xsd “> 输入
} 输出
|
|
Sweepy Dodo · JSON lite的格式化 1 年前 |
|
|
user24242514 · 将嵌套查询字符串请求转换为字典 1 年前 |
|
|
Shane Harley · 通过这些JSON元素进行映射 1 年前 |
|
|
Shane Harley · 将HTML作为JSON字符串的一部分? 1 年前 |
|
|
Matt Miles · 如何将嵌套的JSON转换为数据帧? 1 年前 |