Skip to main content

ARRAY_POPFRONT

description

Remove the first element from array.

Syntax

ARRAY_POPFRONT(<arr>)

Parameters

ParameterDescription
<arr>ARRAY array

Return Value

Returns the array after removing the first element. Special cases:

  • If the input parameter is NULL, returns NULL.

example

select array_popfront(['test', NULL, 'value']);
+-----------------------------------------------------+
| array_popfront(ARRAY('test', NULL, 'value')) |
+-----------------------------------------------------+
| [NULL, "value"] |
+-----------------------------------------------------+