ToObject
ToObject( array )
Not available in this language yet.
Not available in this language yet.
ToObject( array )
Not available in this language yet.
Not available in this language yet.
ToObject( array )
Not available in this language yet.
Parameters
Argument | Type | Definition and Requirements |
---|---|---|
|
An array of arrays containing field names and values. |
Examples
The following query converts an array into an object:
System.out.println(
client.query(
ToObject(
Arr(
Arr(Value("name"), Value("Dennis")),
Arr(Value("age"), Value(37))
)
)
).get());
Not available in this language yet.
Not available in this language yet.
client.query(
q.ToObject([['name', 'Dennis'], ['age', 37]])
)
.then((ret) => console.log(ret))
Not available in this language yet.
Not available in this language yet.
println(Await.result(
client.query(
ToObject(
Arr(
Arr("name", "Dennis"),
Arr("age", 37)
)
)
),
5.seconds
))
Not available in this language yet.
{name: "Dennis", age: 37}
{ name: 'Dennis', age: 37 }
{name: "Dennis", age: 37}
Was this article helpful?
We're sorry to hear that.
Tell us how we can improve!
documentation@fauna.com
Thank you for your feedback!