flatten_all¶
Type of operation: Semistructured
Description¶
Given an input of object or array type, recursively flatten all child elements into ‘_c_NAME_path’ and ‘_c_NAME_value’ columns, including intermediate object/array values. (This is expensive – consider flatten_leaves instead.) The default is to not suggest column types (‘suggesttypes’ = ‘false’.)
Usage¶
flatten_all pathexpression [ , suggesttypes ]
Argument |
Type |
Required |
Multiple |
---|---|---|---|
pathexpression |
fieldref |
Required |
Only one |
suggesttypes |
bool |
Optional |
Only one |
Accelerable¶
flatten_all is always accelerable if the input is accelerable. A dataset that only uses accelerable verbs can be accelerated, making queries on the dataset respond faster.
Examples¶
flatten_all foo
Produce new columns that contain every possible path and its corresponding value. Column ‘foo’ will be removed.
flatten_all foo, true
Produce new columns that contain every possible path and its corresponding value. It will also attempt to determine the value’s type, creating a third column, ‘_c_foo_type’, containing the name of the identified type. Column ‘foo’ will be removed.
Aliases¶
flattenall
(deprecated)