You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- The date related `ProductReceivedProd2` was omitted from this new table.
```{r}
ProductReceivedProd2[ProductSalesProd2,
on = list(product_id, date < date)]
```
which I did not understood initially the full consequences of this, but later, working with my own data, I realised it means losing data from x (if doing x[y, on = .(xid = yid, date < ydate),...]).
I may use something like x[y, on = .(xid = yid), j = .(date = x.date), ...], but then I have to specify inside j = .(...) all the columns from x and y (which may be a lot). I have tried including .SD, x.SD, x..SD, i.SD, i..SD in distinct ways, but nothing of this works.
Is there an abbreviated way to include all x and y (i) columns in the join, while using j to specify some names or some concrete data columns?
The text was updated successfully, but these errors were encountered:
Reading the new join vignettes I found
data.table/vignettes/datatable-joins.Rmd
Lines 557 to 562 in 4f7f567
which I did not understood initially the full consequences of this, but later, working with my own data, I realised it means losing data from
x
(if doingx[y, on = .(xid = yid, date < ydate),...]
).I may use something like
x[y, on = .(xid = yid), j = .(date = x.date), ...]
, but then I have to specify insidej = .(...)
all the columns fromx
andy
(which may be a lot). I have tried including.SD
,x.SD
,x..SD
,i.SD
,i..SD
in distinct ways, but nothing of this works.Is there an abbreviated way to include all
x
andy
(i
) columns in the join, while usingj
to specify some names or some concrete data columns?The text was updated successfully, but these errors were encountered: