[
https://issues.apache.org/jira/browse/CALCITE-5657?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17731261#comment-17731261
]
Julian Hyde commented on CALCITE-5657:
--------------------------------------
If the list is short, it's more efficient to test whether the list is distinct
before creating a HashSet. See {{Util.distinctList(List)}}.
> Add ARRAY_DISTINCT for Spark dialect
> ------------------------------------
>
> Key: CALCITE-5657
> URL: https://issues.apache.org/jira/browse/CALCITE-5657
> Project: Calcite
> Issue Type: Improvement
> Components: core
> Affects Versions: 1.34.0
> Reporter: jackylau
> Assignee: jackylau
> Priority: Major
> Labels: pull-request-available
> Fix For: 1.35.0
>
> Time Spent: 1h 50m
> Remaining Estimate: 0h
>
> {{ARRAY_DISTINCT}} - Returns the input ARRAY with unique elements. If the
> array itself is null, the function will return null. Keeps ordering of
> elements.
> For more details
> https://spark.apache.org/docs/latest/sql-ref-functions-builtin.html
--
This message was sent by Atlassian Jira
(v8.20.10#820010)