snowflake.snowpark.functions.array_distinct¶
- snowflake.snowpark.functions.array_distinct(col: Union[Column, str])[source]¶
The function excludes any duplicate elements that are present in the input ARRAY. The function is not guaranteed to return the elements in the ARRAY in a specific order. The function is NULL safe, which means that it treats NULLs as known values when identifying duplicate elements.
- Parameters:
col – The array column
- Returns:
Returns a new ARRAY that contains only the distinct elements from the input ARRAY.
Example: