top of page

Flatten & Explode

Updated: Aug 22, 2022

Sparkflows provides the Flatten & Explode nodes to extract the columns from complex data types like struct type & array type.


Flatten: Creates the single columns from struct.

Explode: Explode an array columns to rows.


Nodes in fire:

NodeFlatten and NodeExplode

Example Data

ree

Schema

ree

Explode the Topping Column

Explode the array of topping column into rows with new column as explode_topping


ree

Flatten the batters and explode_topping


ree

Final Output

After dropping the few columns


ree


Comments


bottom of page