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



##########
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:
       Shouldn't "swapping" be done on an individual level, e.g. for 
`left1=right1 and right2=left2` it will swap everything now?




-- 
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-unsubscr...@arrow.apache.org

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


Reply via email to