[
https://issues.apache.org/jira/browse/CALCITE-6943?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17942214#comment-17942214
]
Julian Hyde commented on CALCITE-6943:
--------------------------------------
Please, please, please write better summaries. “Hive not support
approx_count_distinct function” describes a bug in Hive.
“Calcite JDBC adapter for Hive should translate APPROX_COUNT_DISTINCT to
something” is what you need here. Note upper case.
> Hive not support approx_count_distinct function
> -----------------------------------------------
>
> Key: CALCITE-6943
> URL: https://issues.apache.org/jira/browse/CALCITE-6943
> Project: Calcite
> Issue Type: Bug
> Components: core
> Affects Versions: 1.39.0
> Reporter: Yu Xu
> Assignee: Yu Xu
> Priority: Major
> Labels: pull-request-available
> Fix For: 1.40.0
>
>
> Hive had not supported approx_count_distinct or apporx_count function yet, so
> we should keep the default way convert approx_count_distinct to count
> distinct.
>
> *test from Hive 1.x to Hive 4.x in beeline:*
> select approx_count_distinct(agg) from test.db01;
> *>FAILED: SemanticException [Error 10011]: Invalid function
> approx_count_distinct*
>
> select approx_distinct(agg) from test.db01;
> *>FAILED: SemanticException [Error 10011]: Invalid function approx_distinct*
>
> we can refer to:
> [https://hive.apache.org/docs/latest/hive-udfs_282102277/#mathematical-functions]
> currently not support such function.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)