make_object¶
Description¶
Turn a sequence of name:value elements into an object. Without arguments, returns an empty, non-null object literal.
Return type¶
any
Domain¶
This is a scalar function (calculates a single output value for a single input row.)
Categories¶
Usage¶
make_object( [ options ] [ , key_value ] ... )
Argument |
Type |
Required |
Multiple |
---|---|---|---|
options |
options |
Optional |
Only one |
key_value |
any |
Optional |
Can be multiple |
Options¶
Option |
Type |
Meaning |
---|---|---|
keep_nulls |
bool |
Determines whether key-value pairs with null values are kept in the object ( |
Examples¶
make_col obj:make_object(label:"speed", value:distance/(endtime-starttime), attime:endtime)
Make a new column ‘obj’ consisting of an object with keys ‘label’, ‘value’, and ‘attime’.
make_col obj:make_object()
Make a new column ‘obj’ consisting of an empty object that is not ‘null’.
Aliases¶
makeobject
(deprecated)