Array elements to columns

Supported in: Batch

Extracts elements from an array into columns.

Transform categories: Array

Declared arguments

  • Array - The array to extract columns from.
    Expression<Array<AnyType>>
  • Columns to extract - List of columns names.
    List<Literal<String>>
  • Dataset - Dataset to drop columns from.
    Table

Examples

Example 1: Base case

Argument values:

  • Array: stats
  • Columns to extract: [miles, id]
  • Dataset: ri.foundry.main.dataset.a

Input:

stats
[ 1000, 2 ]

Output:

milesidstats
10002[ 1000, 2 ]

Example 2: Base case

Argument values:

  • Array: stats
  • Columns to extract: [miles, id]
  • Dataset: ri.foundry.main.dataset.a

Input:

stats
[ 1000, 2, 10 ]
[ 2000 ]

Output:

milesidstats
10002[ 1000, 2, 10 ]
2000null[ 2000 ]

Example 3: Null case

Argument values:

  • Array: stats
  • Columns to extract: [miles, id]
  • Dataset: ri.foundry.main.dataset.a

Input:

stats
[ null, null ]
null

Output:

milesidstats
nullnull[ null, null ]
nullnullnull