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

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

HanumathRao commented on a change in pull request #1426: DRILL-6671: Multi 
level lateral unnest join is throwing an exception …
URL: https://github.com/apache/drill/pull/1426#discussion_r208685651
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/planner/physical/visitor/LateralUnnestRowIDVisitor.java
 ##########
 @@ -64,7 +66,14 @@ public Prel visitLateral(LateralJoinPrel prel, Boolean 
value) throws RuntimeExce
     children.add(((Prel)prel.getInput(0)).accept(this, value));
     children.add(((Prel) prel.getInput(1)).accept(this, true));
 
-    return (Prel) prel.copy(prel.getTraitSet(), children);
+    if (!value) {
+      return (Prel) prel.copy(prel.getTraitSet(), children);
+    } else {
+      CorrelationId corrId = new CorrelationId(prel.getCorrelationId().getId() 
+ 1);
 
 Review comment:
   As discussed offline. I have used the same code as that of 
ProjectCorrelateTransposeRule to replace correlate variables.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Multi level lateral unnest join is throwing an exception during materializing 
> the plan.
> ---------------------------------------------------------------------------------------
>
>                 Key: DRILL-6671
>                 URL: https://issues.apache.org/jira/browse/DRILL-6671
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Query Planning & Optimization
>    Affects Versions: 1.15.0
>            Reporter: Hanumath Rao Maduri
>            Assignee: Hanumath Rao Maduri
>            Priority: Major
>
> testMultiUnnestAtSameLevel in TestE2EUnnestAndLateral is throwing an 
> execution in Materializer.java. This is due to incorrect matching of Unnest 
> and Lateral join. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to