ARRAY_SIZE
Function
Return the number of elements in an array.
Syntax
ARRAY_SIZE(arr)
Parameters
arr:ARRAY<T>.
Return value
- Returns how many elements
arrcontains.
Usage notes
- If the input
arrisNULL, returnsNULL.
Examples
-
Arrays:
ARRAY_SIZE([1, 2, 3])->3ARRAY_SIZE(['a', NULL, 'b'])->3
-
If the input
arrisNULL, returnsNULLARRAY_SIZE(NULL)->NULL