[
https://issues.apache.org/jira/browse/HIVE-6167?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13868145#comment-13868145
]
Alan Gates commented on HIVE-6167:
----------------------------------
My thoughts:
# I agree that built-in UDFs should be in a global space that need not
(probably cannot) be qualified. Everyone needs access to them, and I can't see
any value in adding a namespace here.
# Permanent functions added by users or admins should be in a database. This
gives us namespace separation, it fits with the SQL standard, and I think it
will fit in better with where we're trying to take the security model. I'm
fine with {{create function}} defaulting to the current (not necessarily the
default) data base if users don't specify which database.
# Temporary functions are really session specific (they go away once the user
disconnects) and can't be accessed by any other session, correct? So I think
it's fine to view them as "global" for the purposes of that session. The
following sequence should work:
## {{use db foo}}
## {{create temporary function a();}}
## {{use db bar}}
## {{select a( x ) from T}}
> Allow user-defined functions to be qualified with database name
> ---------------------------------------------------------------
>
> Key: HIVE-6167
> URL: https://issues.apache.org/jira/browse/HIVE-6167
> Project: Hive
> Issue Type: Sub-task
> Components: UDF
> Reporter: Jason Dere
> Assignee: Jason Dere
>
> Function names in Hive are currently unqualified and there is a single
> namespace for all function names. This task would allow users to define
> temporary UDFs (and eventually permanent UDFs) with a database name, such as:
> CREATE TEMPORARY FUNCTION userdb.myfunc 'myudfclass';
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)