srini_polimera
3 years agoNew Contributor III
Json object
I need help to get below output.
[
{
“key1”:“value1”,
“key2”:“value2”
},
{
“key3”:“value3”,
“key4”:“value4”
}
]
expected result
{
“item”:
[
{
“key1”:“value1”,
“key2”:“value2”
},
{
“key3”:“value3”,
“key4”:“value4”
}
]
}
Thanks for your help.
Since they are separate objects, you have to find a way to combine them into one.
Instead of Union, you can use Join with the following configuration:
This will merge both objects into one, then you can easily check if countbefore is equal to countafter with the Filter:$['$countbefore'] == $['$countafter']
Or, you can use an inner Join instead of the combination with Join + Filter:
If their values are the same, there will be an output.