Skip to content

Merge and [ should have an argument for avoid matching of NA #819

@juancentro

Description

@juancentro

Actually, NA matches NA in both merge and [. To emulate SQL behavior, there should be an argument to avoid NA matching with anything

d = data.table
d(a=c(1:2,NA,NA))[d(a=c(2:3,NA,NA)), on="a"]
# should return only 2:3

Metadata

Metadata

Assignees

No one assigned

    Labels

    consistencyfeature requestjoinsUse label:"non-equi joins" for rolling, overlapping, and non-equi joins

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions