Skip to content

DT[j ,c("COL1", "NEW_COL"):=list(COL2, newValue)] returns error if j does not match #2829

@cguill95

Description

@cguill95

The below script illustrates the issue

DT <- data.table(
COL_INT = 1L,
COL_INT_2 = 5L,
)

# Works
DT[COL_INT == 0L, c("COL_INT", "NEW_COL"):=list(9L, "Test")]

# Does not work
DT[COL_INT == 0L, c("COL_INT", "NEW_COL"):=list(COL_INT_2, "Test")]

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions