blaginin commented on code in PR #14684: URL: https://github.com/apache/datafusion/pull/14684#discussion_r1958663144
########## datafusion/core/tests/dataframe/mod.rs: ########## @@ -1617,9 +1617,19 @@ async fn with_column_renamed() -> Result<()> { // accepts table qualifier .with_column_renamed("aggregate_test_100.c2", "two")? // no-op for missing column - .with_column_renamed("c4", "boom")? - .collect() - .await?; + .with_column_renamed("c4", "boom")?; + + assert_eq!("\ + Projection: aggregate_test_100.c1 AS one, aggregate_test_100.c2 AS two, aggregate_test_100.c3, aggregate_test_100.c2 + aggregate_test_100.c3 AS sum AS total\ Review Comment: Thank you for the thorough reading 🙏 `AS sum AS total` happens because there's an alias over an alias - I believe it's harmless since it just wraps the original expression. There's a function `unalias_nested` that can resolve this, but I don't want to call it because it's recursive and expensive. A potentially better option IMO is to reuse the existing alias in `alias_qualified` and `alias` if it's already there (similar to this PR). This feels like a separate improvement from this PR though -- 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...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org