Index: ql/src/test/results/clientpositive/show_describe_func_quotes.q.out =================================================================== --- ql/src/test/results/clientpositive/show_describe_func_quotes.q.out (revision 0) +++ ql/src/test/results/clientpositive/show_describe_func_quotes.q.out (revision 0) @@ -0,0 +1,20 @@ +PREHOOK: query: SHOW FUNCTIONS 'concat' +PREHOOK: type: SHOWFUNCTIONS +POSTHOOK: query: SHOW FUNCTIONS 'concat' +POSTHOOK: type: SHOWFUNCTIONS +concat +PREHOOK: query: SHOW FUNCTIONS concat +PREHOOK: type: SHOWFUNCTIONS +POSTHOOK: query: SHOW FUNCTIONS concat +POSTHOOK: type: SHOWFUNCTIONS +concat +PREHOOK: query: DESCRIBE FUNCTION 'concat' +PREHOOK: type: DESCFUNCTION +POSTHOOK: query: DESCRIBE FUNCTION 'concat' +POSTHOOK: type: DESCFUNCTION +concat(str1, str2, ... strN) - returns the concatenation of str1, str2, ... strN +PREHOOK: query: DESCRIBE FUNCTION concat +PREHOOK: type: DESCFUNCTION +POSTHOOK: query: DESCRIBE FUNCTION concat +POSTHOOK: type: DESCFUNCTION +concat(str1, str2, ... strN) - returns the concatenation of str1, str2, ... strN Index: ql/src/test/queries/clientpositive/show_describe_func_quotes.q =================================================================== --- ql/src/test/queries/clientpositive/show_describe_func_quotes.q (revision 0) +++ ql/src/test/queries/clientpositive/show_describe_func_quotes.q (revision 0) @@ -0,0 +1,7 @@ +SHOW FUNCTIONS 'concat'; + +SHOW FUNCTIONS concat; + +DESCRIBE FUNCTION 'concat'; + +DESCRIBE FUNCTION concat; Index: ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g (revision 4387) +++ ql/src/java/org/apache/hadoop/hive/ql/parse/Hive.g (working copy) @@ -1287,6 +1287,7 @@ descFuncNames : sysFuncNames + | StringLiteral | Identifier ; Index: ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java =================================================================== --- ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java (revision 4387) +++ ql/src/java/org/apache/hadoop/hive/ql/parse/DDLSemanticAnalyzer.java (working copy) @@ -353,7 +353,7 @@ throws SemanticException { showFunctionsDesc showFuncsDesc; if (ast.getChildCount() == 1) { - String funcNames = unescapeSQLString(ast.getChild(0).getText()); + String funcNames = stripQuotes(ast.getChild(0).getText()); showFuncsDesc = new showFunctionsDesc(ctx.getResFile(), funcNames); } else { @@ -375,10 +375,10 @@ boolean isExtended; if(ast.getChildCount() == 1) { - funcName = ast.getChild(0).getText(); + funcName = stripQuotes(ast.getChild(0).getText()); isExtended = false; } else if(ast.getChildCount() == 2) { - funcName = ast.getChild(0).getText(); + funcName = stripQuotes(ast.getChild(0).getText()); isExtended = true; } else { throw new SemanticException("Unexpected Tokens at DESCRIBE FUNCTION");