Skip to content

Returns an array that is the result of applying the lambda function to each element of the input array.

func.array_transform( <array>, <lambda> )
func.array_transform([1, 2, 3], x -> (x + 1))
┌───────────────────────────────────────────────┐
│ func.array_transform([1, 2, 3], x -> (x + 1)) │
├───────────────────────────────────────────────┤
[2,3,4]
└───────────────────────────────────────────────┘
ARRAY_TRANSFORM( <array>, <lambda> )
SELECT ARRAY_TRANSFORM([1, 2, 3], x -> x + 1);
┌──────────────────────────────────────────┐
│ array_transform([1, 2, 3], x -> (x + 1)) │
├──────────────────────────────────────────┤
│ [2,3,4] │
└──────────────────────────────────────────┘