mdayakar commented on code in PR #5182: URL: https://github.com/apache/hive/pull/5182#discussion_r1570924035
########## hplsql/src/main/java/org/apache/hive/hplsql/functions/FunctionMisc.java: ########## @@ -113,7 +155,9 @@ void currentUser(HplsqlParser.Expr_spec_funcContext ctx) { } public static Var currentUser() { - return new Var("CURRENT_USER()"); + String currentUser = System.getProperty("user.name"); + currentUser = Utils.quoteString(currentUser); + return new Var(currentUser); Review Comment: if the UDF is getting called as a part of select then without quotes it will throw error. Ex: `SELECT Bob ` where as `SELECT 'Bob'` is. a valid statement. So adding single quote. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org For additional commands, e-mail: gitbox-h...@hive.apache.org