Skip to content
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

[R-Forge #2175] Add natural joins i.e. X[Y] when X has no key could use common column names #629

Closed
arunsrinivasan opened this issue Jun 8, 2014 · 4 comments · Fixed by #3571

Comments

@arunsrinivasan
Copy link
Member

@arunsrinivasan arunsrinivasan commented Jun 8, 2014

Submitted by: Matt Dowle; Assigned to: Nobody; R-Forge link

Use matching column names in this case.

As suggested by David Kulp here :

http://lists.r-forge.r-project.org/pipermail/datatable-help/2012-August/001241.html

Or, leave this to merge (since merge.data.table does that)? And if so, document.

@MichaelChirico
Copy link
Member

@MichaelChirico MichaelChirico commented Sep 3, 2015

This is easy now with on, correct? could set default of on to intersect(names(dt1),names(dt2)), for example.

@franknarf1
Copy link
Contributor

@franknarf1 franknarf1 commented Sep 3, 2015

@MichaelChirico I would prefer to see a special value for on (similar to .EACHI), to keep it explicit/transparent, like on=.COMMON.

While we're at it, I suppose there could be an onby (if the logic & code are structured so that that actually makes sense).

@MichaelChirico
Copy link
Member

@MichaelChirico MichaelChirico commented Feb 11, 2016

This seems like a close relative of the recently-closed #1517

@MichaelChirico
Copy link
Member

@MichaelChirico MichaelChirico commented Jun 29, 2017

@franknarf1 in keeping with SQL-inspired syntax, I was thinking on = .NATURAL would be a very natural (sorry) way to implement this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

4 participants