```r DT = data.table(id=c(rep(1L,3), rep(2L, 3)), v=bit64::as.integer64(c(1:3, NA, 5:6))) DT[2:6, sum(v), id] # id V1 # <int> <i64> #1: 1 5 #2: 2 11 DT[, "v" := as.integer(v)] # id V1 # <int> <int> #1: 1 5 #2: 2 NA ``` might be related to #1647
might be related to #1647