Question
How to remove a null element from an array using the Jolt Transformation specification?
I want to remove null elements from the array using the Jolt spec.
Example:
Input:
{
"arrayOne": [
null,
{
"key1": "value1",
"key2": "value2"
}
]
}
Required output:
{
"arrayOne": [
{
"key1": "value1",
"key2": "value2"
}
]
}
I tried using "recursivelySquashNulls"
but that did not work.
[
{
"operation": "modify-overwrite-beta",
"spec": {
"*": "=recursivelySquashNulls"
}
}
]
3 35
3