alamb commented on code in PR #5343:
URL: https://github.com/apache/arrow-datafusion/pull/5343#discussion_r1128452662


##########
datafusion/expr/src/logical_plan/builder.rs:
##########
@@ -545,14 +545,22 @@ impl LogicalPlanBuilder {
 
                     match (&l.relation, &r.relation) {
                         (Some(lr), Some(rr)) => {
-                            let l_is_left =
-                                
self.plan.schema().field_with_qualified_name(lr, &l.name);
-                            let l_is_right =
-                                right.schema().field_with_qualified_name(lr, 
&l.name);
-                            let r_is_left =
-                                
self.plan.schema().field_with_qualified_name(rr, &r.name);
-                            let r_is_right =
-                                right.schema().field_with_qualified_name(rr, 
&r.name);
+                            let l_is_left = 
self.plan.schema().field_with_qualified_name(
+                                &lr.as_table_reference(),

Review Comment:
   I was thinking about removing OwnedTableReference -- I started to sketch out 
what this might look like in 
https://github.com/apache/arrow-datafusion/pull/5508
   
   Working with the structures then I think becomes less cumbersome



##########
docs/source/user-guide/example-usage.md:
##########
@@ -118,8 +118,8 @@ async fn main() -> datafusion::error::Result<()> {
   let ctx = SessionContext::new();
   let df = ctx.read_csv("tests/data/capitalized_example.csv", 
CsvReadOptions::new()).await?;
 
-  let df = df.filter(col("A").lt_eq(col("c")))?
-           .aggregate(vec![col("A")], vec![min(col("b"))])?
+  let df = df.filter(col("\"A\"").lt_eq(col("c")))?
+           .aggregate(vec![col("\"A\"")], vec![min(col("b"))])?
            .limit(0, Some(100))?;

Review Comment:
   How about we simply add an `ident()` function that doesn't parse at all? I 
can help do that



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to