hadoop-hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Namit Jain (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HIVE-741) NULL is not handled correctly in join
Date Mon, 16 Aug 2010 23:14:17 GMT

    [ https://issues.apache.org/jira/browse/HIVE-741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12899177#action_12899177
] 

Namit Jain commented on HIVE-741:
---------------------------------

For inner, left and right outer joins, a simpler fix would be to add a filter on top.

For example, for 

A join B on A.c1 = B.c2


add a filter before A (A.c1 is not null) and B (B.c2 is not null)

For 

A left outer join B on A.c1 = B.c2, the filter before A is not needed and 
similarly, for 
A right outer join B on A.c1 = B.c2, the filter before B is not needed



Some special handling might still be needed for full outer joins and sort-merge joins

> NULL is not handled correctly in join
> -------------------------------------
>
>                 Key: HIVE-741
>                 URL: https://issues.apache.org/jira/browse/HIVE-741
>             Project: Hadoop Hive
>          Issue Type: Bug
>            Reporter: Ning Zhang
>            Assignee: Amareshwari Sriramadasu
>         Attachments: patch-741.txt
>
>
> With the following data in table input4_cb:
> Key        Value
> ------       --------
> NULL     325
> 18          NULL
> The following query:
> {code}
> select * from input4_cb a join input4_cb b on a.key = b.value;
> {code}
> returns the following result:
> NULL    325    18   NULL
> The correct result should be empty set.
> When 'null' is replaced by '' it works.

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


Mime
View raw message