hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lavelle, Shawn" <>
Subject Simple UDFS and IN Operator
Date Tue, 08 Mar 2016 19:32:25 GMT
Hello All,
   I hope that this question isn’t too rudimentary – but I’m relatively new to HIVE.

   In Hive 0.11, I’ve written a UDF that returns a list of Integers. I’d like to use this
in a WHERE clause of a query, something like SELECT * FROM <table> WHERE <col>
 in ( getList() ). (Extra parenthesis needed to pass the parser.)  Is such a thing possible?
 Keying in values for the list parameter works, but they have WritableConstantIntObjectInspectors
whereas what is returned by my list (despite my best efforts) has an element inspector of
WritabeIntObjectInspector. This doesn’t work.

  So, two questions – Should It? (The HIVE I’m working on is heavily modified :/ ) and
how might I accomplish this?  Joins would be ideal, but we haven’t upgraded yet.

  Thank you for your insight,

~ Shawn M Lavelle


Shawn Lavelle
Software Development

4101 Arrowhead Drive
Medina, Minnesota 55340-9457
Phone: 763 551 0559
Fax: 763 551 0750

View raw message