If you trace the source code, you'll find it's not too hard to change to let a user specify a UDF. But, that's changing the code...
Ed Capriolo posted a more useful response a while back, on the general Hive mailing list: "You have the option now to run HQL by creating a hiverc file https://issues.apache.org/jira/browse/HIVE-1414." -Phil On Wed, Jun 27, 2012 at 6:26 AM, Denny Lee <denny.g....@gmail.com> wrote: > Thanks Jasper - much appreciated! > > > On Tue, Jun 26, 2012 at 10:27 PM, Jasper Knulst < > jasper.knu...@incentro.com> wrote: > >> Hi Denny, >> >> I asked the same question a few days ago and got this reference to >> another question: >> >> "If you want to make your temporary function permanent , you have to >> patch hive source code. Please refer to this discussion >> >> http://mail-archives.apache.org/mod_mbox/hive-user/201101.mbox/%3caanlktimbx1rskkwqi1pnnhrjkgc9cjurun_be8yoy...@mail.gmail.com%3E >> " >> >> >> So you are right, the only way seems to be to rebuild hive-exec-* >> yourself. >> >> I solved the issue temporarily by invoking a hive script ( with hive -i >> '/path/to/hive-init.sql') command that does the repetitive commands for >> me. When you create a nix alias (alias hive='hive -i >> "/path/to/hive_init.sql" ') for it it works fine for me. >> >> >> Jasper >> >> >> >> >> 2012/6/27 Denny Lee <denny.g....@gmail.com> >> >>> We have a scenario where we want to make a UDF permanent so that way a >>> query through the HiveODBC driver will be able to access the UDF. I seem >>> to recall that after creating the UDF, you can make it "permanent" by >>> adding it into the Function Registry. >>> >>> But it seems that I also need to rebuild the hive-exec-*.jar and bundle >>> my UDF within it. Is this actually a necessary step or is it possible to >>> register my UDFs and make them permanent? >>> >>> Thanks! >>> Denny >>> >>> >> >> >> -- >> > >