[ 
https://issues.apache.org/jira/browse/HIVE-6622?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14040022#comment-14040022
 ] 

Lefty Leverenz commented on HIVE-6622:
--------------------------------------

User doc for translate(input, from, to) is here:

* [Hive Operators and UDFs -- String Functions | 
https://cwiki.apache.org/confluence/display/Hive/LanguageManual+UDF#LanguageManualUDF-StringFunctions]

so a note should be added to the description, saying CHAR and VARCHAR are 
supported as of Hive 0.14.0 and linking to this jira.  Also, the name/signature 
column should show CHAR and VARCHAR alternatives.

> UDF translate doesn't take either CHAR or VARCHAR as any of its arguments
> -------------------------------------------------------------------------
>
>                 Key: HIVE-6622
>                 URL: https://issues.apache.org/jira/browse/HIVE-6622
>             Project: Hive
>          Issue Type: Bug
>          Components: UDF
>    Affects Versions: 0.12.0
>            Reporter: Xuefu Zhang
>            Assignee: Wilbur Yang
>              Labels: TODOC14
>             Fix For: 0.14.0
>
>         Attachments: HIVE-6622.1.patch
>
>
> UDF translate(input, from, to) doesn't accept any CHAR or VARCHAR typed 
> argument.
> {code}
> hive> desc vc;
> c                     char(5)                 None                
> vc                    varchar(7)              None                
> s                     string                  None                
> hive> select translate("my input", c, "ll") from vc;
> FAILED: SemanticException [Error 10016]: Line 1:29 Argument type mismatch 
> 'c': A string argument was expected but an argument of type char(5) was given.
> {code}
> However, if the type is String, then the UDF works fine.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to