-
Notifications
You must be signed in to change notification settings - Fork 323
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow a Table to be used to rename_columns
.
#9940
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, but I think we should test the error scenarios as well (using DB table with DB table and with in-memory table).
Because Enso language is so dynamic, I just can't trust an error scenario that is untested - we've historically had far too many cases of untested error scenarios that actually crashed because of a typo. Well, at least I wouldn't trust myself about it if I had written this without tests.
@@ -2967,7 +2961,7 @@ default_join_condition table join_kind = case join_kind of | |||
## PRIVATE | |||
Table.from (that:DB_Table) = | |||
_ = [that] | |||
Error.throw (Illegal_Argument.Error "Currently cross-backend operations are not supported. Materialize the table using `.read` before mixing it with an in-memory Table.") | |||
Error.throw (Illegal_Argument.Error "This operation requires the data in-memory, materialize the table using `.read`.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds much better :)
Pull Request Description
Following an example from Steve, adjusted
rename_column
to allow aTable
to define the mapping.DB_Table
is passed errors and tells the user to materialize the table.Checklist
Please ensure that the following checklist has been satisfied before submitting the PR:
Scala,
Java,
TypeScript,
and
Rust
style guides. In case you are using a language not listed above, follow the Rust style guide.