There doesn't seem to be a way to merge (join) while ignoring case. The SQL equivalent to this would be UPPER(employees.FirstName) = UPPER(work.FirstName) from here. I'd like to propose adding a boolean argument to allow this as ignore.case. Thanks!
R version 3.6.1 (2019-07-05)
Platform: x86_64-apple-darwin15.6.0 (64-bit)
Running under: macOS Mojave 10.14.3
Matrix products: default
BLAS: /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/3.6/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] patchwork_1.0.0 ggforce_0.3.1 ggplot2_3.2.1 dplyr_0.8.3 janitor_1.2.0 data.table_1.12.8
loaded via a namespace (and not attached):
[1] Rcpp_1.0.2 rstudioapi_0.10 magrittr_1.5 MASS_7.3-51.4 tidyselect_0.2.5 munsell_0.5.0 colorspace_1.4-1
[8] R6_2.4.0 rlang_0.4.2 stringr_1.4.0 tools_3.6.1 grid_3.6.1 packrat_0.5.0 gtable_0.3.0
[15] withr_2.1.2 digest_0.6.20 lazyeval_0.2.2 assertthat_0.2.1 tibble_2.1.3 crayon_1.3.4 farver_2.0.1
[22] tweenr_1.0.1 purrr_0.3.3 snakecase_0.11.0 glue_1.3.1 labeling_0.3 polyclip_1.10-0 stringi_1.4.3
[29] compiler_3.6.1 pillar_1.4.2 scales_1.0.0 pkgconfig_2.0.3
A fully reproducible example of your use case would go a long way. In particular, it's not clear whether you're doing x[y] joins or merge(x, y) joins.
In the meantime, I think this would basically be covered by #1639 -- x[y, on = .(tolower(id) == tolower(id)] seems like a natural fit.
Most helpful comment
A fully reproducible example of your use case would go a long way. In particular, it's not clear whether you're doing
x[y]joins ormerge(x, y)joins.In the meantime, I think this would basically be covered by #1639 --
x[y, on = .(tolower(id) == tolower(id)]seems like a natural fit.