-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
FR: UPDATE- and UPSERT-like functionality #2075
Comments
@hadley: Is that something we want here or in tidyr? |
This feels more like dplyr to me, although there's clearly some connection to tidyverse/tidyr#183 |
Do you think a single verb Might need some variant as to whether an NA on the RHS should be treated as a literal NA, or just means to leave the LHS value as is. |
I think a single verb that always does a full join should be sufficient. See #1792 for a discussion about keys. We'd have to assume (or check) that the join keys are unique for both datasets (#1619). Treating NA on the RHS as literal NA feels difficult to implement for SQL sources. All in all, because this functionality can be implemented completely using existing |
Ok, lets keep discussion there |
Sometimes I need to update a bunch of observations in a target table with information from a second table. Currently, I'm doing something like
It would be great if dplyr offered a verb that does this for me. Unlike #1736 and #1216, that verb would create a new table. The code above implements UPDATE, if full_join() is used instead, it's more like UPSERT.
The text was updated successfully, but these errors were encountered: