ARRAY_POPBACK
descriptionβ
Remove the last element from array.
Syntaxβ
ARRAY_POPBACK(<arr>)
Parametersβ
Parameter | Description |
---|---|
<arr> | ARRAY array |
Return Valueβ
Returns the array after removing the last element. Special cases:
- If the input parameter is NULL, returns NULL.
exampleβ
select array_popback(['test', NULL, 'value']);
+-----------------------------------------------------+
| array_popback(ARRAY('test', NULL, 'value')) |
+-----------------------------------------------------+
| ["test", NULL] |
+-----------------------------------------------------+