Home Forums SQL Server 2008 T-SQL (SS2K8) comparison in the merge statement about null values RE: comparison in the merge statement about null values

  • Evil Kraig F (8/22/2012)


    sqlfriends (8/22/2012)


    can I use isnull(student.mailingaddress,'')<>isnull(esis.mailingaddress,'')

    Yep, that's the usual workaround, just realize the entire query will be non-SARGable.

    I would like my query to be sargable.

    So what other good approach to do the comparison but still keep null compare valid?

    Thanks.