[
https://issues.apache.org/jira/browse/PHOENIX-4866?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
cherish peng updated PHOENIX-4866:
----------------------------------
Priority: Blocker (was: Major)
> UDFs get error: org.apache.phoenix.schema.FunctionNotFoundException: ERROR
> 6001 (42F01): Function undefined
> -----------------------------------------------------------------------------------------------------------
>
> Key: PHOENIX-4866
> URL: https://issues.apache.org/jira/browse/PHOENIX-4866
> Project: Phoenix
> Issue Type: Bug
> Affects Versions: 5.0.0
> Environment: [^ArrayDistinctFunction.java]
> Reporter: cherish peng
> Priority: Blocker
> Labels: functions, udfs
> Attachments: ArrayDistinctFunction.java
>
> Original Estimate: 72h
> Remaining Estimate: 72h
>
> I built an udf `ARRAY_DISTINCT`, When i exec:
> {color:#d04437}①{color} SELECT ARRAY_DISTINCT(ARRAY['A', 'B', 'A', 'C'],
> TRUE);
> throw error: "org.apache.phoenix.schema.FunctionNotFoundException: ERROR 6001
> (42F01): Function undefined"
> However when i exec:
> {color:#d04437}②{color} SELECT ARRAY_DISTINCT(ARRAY['A', 'B', 'A', 'C'],
> TRUE) {color:#f79232}FROM TABLE_NAME;{color}
> output:
> *+---------------------+*
> *|* *ARRAY['A','B','C']* *|*
> *+---------------------+*
> *+---------------------+*
>
> {color:#d04437}③{color} SELECT
> ARRAY_DISTINCT({color:#f79232}array_elements{color}, TRUE) as arr
> {color:#f79232}FROM TABLE_NAME;{color}*{color:#f79232}
> {color}*
> {color:#f79232}{color:#333333}output:{color}
> {color}
> *+---------------------+*
> *| ARR* ** *|*
> *+---------------------+*
> *| ARRAY['A','B','C'] |***
> *+---------------------+*
>
> *I tried the built-in functions which provided by Phoenix, they only output
> {color:#d04437}③{color} .*
> *I put the ARRAY_DISTINCT SOURCE TO attachment.*
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)