06-18-2018 11:48 AM
I have the following JSON. I’m struggling on how to write a mapper that captures $[0].original from the JSON below…
[
{
“Id”: “0036A00000AbbdpQAB”,
“FirstName”: “Andrew”,
“LastName”: “Ramirez”,
“hed__AlternateEmail__c”: “aramirez@destinysolutions.com”,
“original”: {
“FirstName”: “Andrew”,
“LastName”: “Ramirezy”,
“Email”: “aramirez@destinysolutions.com”
}
},
{
“Id”: “0036A00000AbbeOQAR”,
“FirstName”: “Andrew”,
“LastName”: “Mayzak”,
“hed__AlternateEmail__c”: “4541474710648498@destinysolutions.com”,
“original”: {
“FirstName”: “Andrew”,
“LastName”: “Ramirezy”,
“Email”: “aramirez@destinysolutions.com”
}
},
{
“Id”: “0036A00000Vatj6QAB”,
“FirstName”: “Andrew”,
“LastName”: “Ramirez”,
“hed__AlternateEmail__c”: “aramirez@destinsolutions.com”,
“original”: {
“FirstName”: “Andrew”,
“LastName”: “Ramirezy”,
“Email”: “aramirez@destinysolutions.com”
}
}
]
$original is validated by SnapLogic but returns me an array which is not what I want…
$[0] fails validation by SnapLogic. Can anyone suggest valid JSONPath syntax in SnapLogic that will select the $original subtree in the first element of the root array?
06-19-2018 05:25 AM
Use JSON Splitter
06-19-2018 06:51 AM
@SandeepVemula … I tried a JSON splitter but it doesn’t appear to work…
Here’s my attached pipeline
SFTestReadMulti_2018_06_19.slp (9.1 KB)
06-19-2018 09:09 PM
Use Head Snap