array(expr, ...) |
Returns an array with the given elements. |
array_contains(array, value) |
Returns true if the array contains the value. |
array_distinct(array) |
Removes duplicate values from the array. |
array_except(array1, array2) |
Returns an array of the elements in array1 but not in array2,
without duplicates. |
array_intersect(array1, array2) |
Returns an array of the elements in the intersection of array1 and
array2, without duplicates. |
array_join(array, delimiter[, nullReplacement]) |
Concatenates the elements of the given array
using the delimiter and an optional string to replace nulls. If no value is set for
nullReplacement, any null value is filtered. |
array_max(array) |
Returns the maximum value in the array. NaN is greater than
any non-NaN elements for double/float type. NULL elements are skipped. |
array_min(array) |
Returns the minimum value in the array. NaN is greater than
any non-NaN elements for double/float type. NULL elements are skipped. |
array_position(array, element) |
Returns the (1-based) index of the first element of the array as long. |
array_remove(array, element) |
Remove all elements that equal to element from array. |
array_repeat(element, count) |
Returns the array containing element count times. |
array_union(array1, array2) |
Returns an array of the elements in the union of array1 and array2,
without duplicates. |
arrays_overlap(a1, a2) |
Returns true if a1 contains at least a non-null element present also in a2. If the arrays have no common element and they are both non-empty and either of them contains a null element null is returned, false otherwise. |
arrays_zip(a1, a2, ...) |
Returns a merged array of structs in which the N-th struct contains all
N-th values of input arrays. |
flatten(arrayOfArrays) |
Transforms an array of arrays into a single array. |
sequence(start, stop, step) |
Generates an array of elements from start to stop (inclusive),
incrementing by step. The type of the returned elements is the same as the type of argument
expressions.
Supported types are: byte, short, integer, long, date, timestamp.
The start and stop expressions must resolve to the same type.
If start and stop expressions resolve to the 'date' or 'timestamp' type
then the step expression must resolve to the 'interval' or 'year-month interval' or
'day-time interval' type, otherwise to the same type as the start and stop expressions. |
shuffle(array) |
Returns a random permutation of the given array. |
slice(x, start, length) |
Subsets array x starting from index start (array indices start at 1, or starting from the end if start is negative) with the specified length. |
sort_array(array[, ascendingOrder]) |
Sorts the input array in ascending or descending order
according to the natural ordering of the array elements. NaN is greater than any non-NaN
elements for double/float type. Null elements will be placed at the beginning of the returned
array in ascending order or at the end of the returned array in descending order. |