Created 03-08-2022 02:41 PM
I am a newbie to Nifi Jolt transform. I've been looking through the document, but still cannot figure out how to do a simple Jolt Transform.
Input:
{"id": 123456,
"manager_id": 98765}
desired output:
{"reportTo": [{"userId": 98765}]}
I've got the part to change the manager_id to userId by the following Spec. But I was stuck how to make it another layer. Any insights/help to solve this?
[{
"operation": "shift",
"spec": {
"manager_id": "userId"}
}
}]
Created 03-08-2022 03:26 PM
Try this one out:
[
{
"operation": "shift",
"spec": {
"id": "&",
"manager_id": "report_to[0].id"
}
}
]
Cheers,
André
Created 03-08-2022 03:26 PM
Try this one out:
[
{
"operation": "shift",
"spec": {
"id": "&",
"manager_id": "report_to[0].id"
}
}
]
Cheers,
André
Created 03-09-2022 05:46 AM
This works perfectly! Thank you