Open araval6969 opened 1 year ago
Hi @araval6969 You can use this to solve it:
[
{
"operation": "modify-default-beta",
"spec": {
"*": {
"fullName": "=concat(@(1,firstName),' ',@(1,lastName))"
}
}
},
{
"operation": "shift",
"spec": {
"*": {
"fullName": "names",
"state": "states"
}
}
}
]
Could any one please help with jolt transformation of following type of operation?
json array: [ { "firstName": "Fname1", "lastName": "Lname1", "state": "PA" }, { "firstName": "Fname2", "lastName": "Lname2", "state": "VA" }, { "firstName": "Fname3", "lastName": "Lname3", "state": "CA" } ]
expected output:
{ names:["Fname1 Lname1", "Fname2 Lname2","Fname3 Lname3"] states:["PA","VA","CA"] }