You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/07/26 21:10:54 UTC

[GitHub] [arrow-datafusion] seddonm1 commented on a change in pull request #778: JOIN conditions are order dependent

seddonm1 commented on a change in pull request #778:
URL: https://github.com/apache/arrow-datafusion/pull/778#discussion_r676947049



##########
File path: datafusion/src/logical_plan/builder.rs
##########
@@ -282,14 +282,42 @@ impl LogicalPlanBuilder {
             ));
         }
 
+        let left_keys = left_keys
+            .into_iter()
+            .map(|c| c.into())
+            .collect::<Vec<Column>>();
+
+        let mut swap = false;
         let left_keys: Vec<Column> = left_keys
+            .clone()
             .into_iter()
-            .map(|c| c.into().normalize(&self.plan))
-            .collect::<Result<_>>()?;
+            .map(|c| c.normalize(&self.plan))
+            .collect::<Result<_>>()
+            .or_else(|_| {
+                swap = true;

Review comment:
       Yes, thanks for you review. I will address this.




-- 
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.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org