xiedeyantu commented on code in PR #21236:
URL: https://github.com/apache/datafusion/pull/21236#discussion_r3008277142


##########
datafusion/expr/src/logical_plan/plan.rs:
##########
@@ -2406,6 +2406,28 @@ impl SubqueryAlias {
         let aliases = unique_field_aliases(plan.schema().fields());
         let is_projection_needed = aliases.iter().any(Option::is_some);
 
+        // Collect the set of unqualified field names that are ambiguous in 
this

Review Comment:
   @xudong963 Thank you very much for your review and excellent suggestions. My 
initial intention for this PR was to eliminate the unique naming 
convention—specifically, the `name:N` format—but it appears to play a critical 
role internally (it would be great if you could provide some further details on 
this). Consequently, I introduced an additional `ambiguous_names` field to 
track duplicate column names. To be honest, I felt this approach lacked 
elegance, but I couldn't come up with a better alternative at the time. Having 
reviewed your suggestions, however, I now believe they offer a superior 
solution; I will proceed to refactor this PR based on that approach. I will 
also add the corresponding SLT tests.



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to