hive-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (Jira)" <>
Subject [jira] [Work logged] (HIVE-24087) FK side join elimination in presence of PK-FK constraint
Date Tue, 01 Sep 2020 15:16:00 GMT


ASF GitHub Bot logged work on HIVE-24087:

                Author: ASF GitHub Bot
            Created on: 01/Sep/20 15:15
            Start Date: 01/Sep/20 15:15
    Worklog Time Spent: 10m 
      Work Description: vineetgarg02 merged pull request #1440:


This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:

Issue Time Tracking

    Worklog Id:     (was: 477269)
    Time Spent: 1h 10m  (was: 1h)

> FK side join elimination in presence of PK-FK constraint
> --------------------------------------------------------
>                 Key: HIVE-24087
>                 URL:
>             Project: Hive
>          Issue Type: Improvement
>          Components: Query Planning
>            Reporter: Vineet Garg
>            Assignee: Vineet Garg
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 1h 10m
>  Remaining Estimate: 0h
> If there is PK-FK join FK join could be eliminated by removing FK side if following conditions
are met
> * There is no row filtering on FK side.
> * No columns from FK side is required after JOIN.
> * FK join columns are guranteed to be unique (have group by)
> * FK join columns are guranteed to be NOT NULL (either IS NOT NULL filter or constraint)
> *Example*
> {code:sql}
> SELECT customer_removal_n0.*
> FROM customer_removal_n0
>     JOIN
>     (SELECT lo_custkey
>     FROM lineorder_removal_n0
>     WHERE lo_custkey IS NOT NULL
>     GROUP BY lo_custkey) fkSide ON fkSide.lo_custkey = customer_removal_n0.c_custkey;
> {code}

This message was sent by Atlassian Jira

View raw message