I have an Array of Jsons and I want to transform the keys of individual Jsons while still maintaining the Array.
[
{
"a": "1",
"b": "2"
},
{
"a": "one",
"b": "two"
}
]
Desired output:
[
{
"my_a": "1",
"my_b": "2"
},
{
"my_a": "one",
"my_b": "two"
}
]
JOLT Spec:
[
{
"operation": "shift",
"spec": {
"*": {
"a": "my_a",
"b": "my_b"
}
}
}
]
However, I see this:
{
"my_a" : [ "1", "one" ],
"my_b" : [ "2", "two" ]
}
I see that the transformation is applied but the output is not what I expect.
Anyone who has faced similar problems?
