[ 
https://issues.apache.org/jira/browse/HIVE-790?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ning Zhang updated HIVE-790:
----------------------------

    Attachment: Hive-790.patch

This patch solves the bug in "UNION ALL" two SCRIPT operators but only show 
results from one operator. The reason is because the UNION Operator has two 
parents and when one of the parent is still OPEN, it shouldn't close its child 
operator. 

Will look the race condition issue and try to reproduce it.

> race condition related to ScriptOperator + UnionOperator
> --------------------------------------------------------
>
>                 Key: HIVE-790
>                 URL: https://issues.apache.org/jira/browse/HIVE-790
>             Project: Hadoop Hive
>          Issue Type: Bug
>            Reporter: Zheng Shao
>            Assignee: Ning Zhang
>         Attachments: Hive-790.patch
>
>
> ScriptOperator uses a second thread to output the rows to the children 
> operators. In a corner case which contains a union, 2 threads might be 
> outputting data into the same operator hierarchy and caused race conditions.
> {code}
> CREATE TABLE tablea (cola STRING);
> SELECT *
> FROM (
>     SELECT TRANSFORM(cola)
>     USING 'cat'
>     AS cola
>     FROM tablea
>   UNION ALL
>     SELECT cola as cola
>     FROM tablea
> ) a;
> {code}

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

Reply via email to