array_append
function
Applies to: Databricks SQL Databricks Runtime 12.2 LTS and above
Returns array
appended by elem
.
Syntax
array_append(array, elem)
Arguments
array
: An ARRAY.elem
: An expression of the same type as the elements ofarray
.
Returns
An ARRAY of the same type as array
.
Examples
> SELECT array_append(array(1, 2, 3), 0);
[1,2,3,0]
> SELECT array_append(array(1, 2, 3), NULL);
[1,2,3,NULL]
Related functions
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for