ARRAY_JOIN
Concatenates the elements of the given array using the specified delimiter.
ARRAY_JOIN(X, DELIMITER)
Type:
array
An array of any value type.
Type:
string
The delimiter used to join the values within the array.
Type:
string
The values of the array
X
joined with DELIMITER
.X | DELIMITER | Output |
---|---|---|
[a, b, c] | , | a,b,c |
[5.5] | , | 5.5 |
[hello, NULL, world] | | hello world |
[brave, NULL, world] | new | brave new world |
[3,6,1,2] | , | 3,6,1,2 |
[5.5] | NULL | NULL |
CREATE JOB function_operator_example
ADD_MISSING_COLUMNS = true
AS INSERT INTO default_glue_catalog.upsolver_samples.orders_transformed_data MAP_COLUMNS_BY_NAME
SELECT
ARRAY_JOIN(ARRAY['hello', null::string ,'world'], ' ') AS join_example
FROM default_glue_catalog.upsolver_samples.orders_raw_data
WHERE time_filter()
GROUP BY shippinginfo_address_state
LIMIT 1;
join_example |
---|
hello world |
Last modified 28d ago