timsaucer commented on code in PR #908:
URL: https://github.com/apache/datafusion-python/pull/908#discussion_r1798465440
##########
python/datafusion/dataframe.py:
##########
@@ -175,7 +178,23 @@ def with_column_renamed(self, old_name: str, new_name:
str) -> DataFrame:
Returns:
DataFrame with the column renamed.
"""
- return DataFrame(self.df.with_column_renamed(old_name, new_name))
+ return DataFrame(self.df.rename({old_name: new_name}))
+
+ def rename(self, mapping: dict[str, str]) -> DataFrame:
+ r"""Rename one or multiple columns by applying a new projection.
Review Comment:
I'd like to hear other people's opinions. Also I don't recommend we stray
*too far* from what the upstream DataFusion uses for naming conventions.
--
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]