Hey, I have this array of objects:
[
{
"Name" : "Bob"
},
"Email" : "Bob@hotmail.com"
},
{
"DOB" : "19901025"
}
]
And I would like to convert it into one object:
[
{
"Name" : "Bob",
"Email" : "Bob@hotmail.com",
"DOB" : "19901025"
}
]
It would be a bonus if I can move this object out of the array since it will be the only entry, but any help is welcome. Thanks!
Hello @memorablename ,
I'd probably brute-force this. Convert the initial array with the object into string:
string(<yourInput>)
replace },{ with only a comma:
replace(string(<yourInput>),'},{',',')
turn it back into an array with an object:
json(replace(string(<yourInput>),'},{',','))
get rid of the array and keep only the object (first value in the array)
first(json(replace(string(<yourInput>),'},{',',')))
Michael E. Gernaey
497
Super User 2025 Season 1
David_MA
436
Super User 2025 Season 1
Riyaz_riz11
244
Super User 2025 Season 1