hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zheng Shao (JIRA)" <>
Subject [jira] Commented: (HIVE-655) Add support for user defined table generating functions
Date Tue, 13 Oct 2009 22:41:31 GMT


Zheng Shao commented on HIVE-655:

We had an offline design meeting and here are some conclusions:

1. Grammar:
SELECT myUDTF(expression1, expression2 ...) AS col1, col2, col3
FROM src;

The column names after AS is required for now.

2. UDTF class hierarchy:
We will have an abstract base class UDTF that have the following interface. The interface
is simplified from Operator interface.
abstract ObjectInspector init(ObjectInspector row); // take input row OI and output output
row OI
abstract void process(Object o); // Get a row and process it
abstract void close(); // Notify that the data stream is ended
final void forward(Object o); // called by UDTF to forward the row that is generated

3. UDTF creation statement. Follow the same way as UDF and UDAF.

> Add support for user defined table generating functions
> -------------------------------------------------------
>                 Key: HIVE-655
>                 URL:
>             Project: Hadoop Hive
>          Issue Type: New Feature
>          Components: Query Processor
>            Reporter: Raghotham Murthy
>            Assignee: Raghotham Murthy
> Provide a way for users to add a table generating function, i.e., functions that generate
multiple rows from a single input row. Currently, the only way to do it is via the TRANSFORM
clause which requires streaming the data.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message