[ 
https://issues.apache.org/jira/browse/DRILL-3690?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14708184#comment-14708184
 ] 

ASF GitHub Bot commented on DRILL-3690:
---------------------------------------

GitHub user mehant opened a pull request:

    https://github.com/apache/drill/pull/127

    DRILL-3690: Fix partition pruning rule to correctly build new filter …

    …when original filter contains nested expressions

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/mehant/drill prune_rule

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/drill/pull/127.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #127
    
----
commit 1dcc394c606df33325357ffc6e19134802098c9e
Author: Mehant Baid <[email protected]>
Date:   2015-08-22T06:51:38Z

    DRILL-3690: Fix partition pruning rule to correctly build new filter when 
original filter contains nested expressions

----


> Partitioning pruning produces wrong results when there are nested expressions 
> in the filter
> -------------------------------------------------------------------------------------------
>
>                 Key: DRILL-3690
>                 URL: https://issues.apache.org/jira/browse/DRILL-3690
>             Project: Apache Drill
>          Issue Type: Bug
>            Reporter: Mehant Baid
>            Assignee: Mehant Baid
>            Priority: Blocker
>             Fix For: 1.2.0
>
>
> Consider the following query:
> select 1 from foo where dir0 not in (1994) and col1 not in ('bar');
> The filter condition is: AND(NOT(=($1, 1994)), NOT(=($2, 'bar')))
> In FindPartitionCondition we rewrite the filter to cherry pick the partition 
> column conditions so the interpreter can evaluate it, however when the 
> expression contains more than two levels of nesting (in this case 
> AND(NOT(=))) ) the expression does not get rewritten correctly. In this case 
> the expression gets rewritten as: AND(=($1, 1994)). NOT is missing from the 
> rewritten expression producing wrong results.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to