This documentation is related to an older version of Firebolt. For the most current documentation, see Firebolt documentation.
LENGTH
Returns the length of (number of elements in) the given array.
Syntax
LENGTH(<array>)
Parameters
Parameter | Description | Supported input types |
---|---|---|
<array> | The array to be checked for length. | ARRAY |
Return Type
INTEGER
Example
SELECT
LENGTH([ 1, 2, 3, 4 ]) AS levels;
Returns: 4