Remove duplicates but keep null

Is there a way to remove duplicates but keep nulls?

 

I need to keep null values because that indicates a certain client hasn't reached a stage of our onboarding yet, but if data needs to be run twice in one day for some reason I don't want it to remove the nulls or else that defeats the purpose.

 

Anyway, thanks!

Comments

  • Hi,

    Is anyone able to help out with this request?


    Thanks,

  • YangLu
    YangLu Member

    Can try replace Null value with a dummy value of Row ID, for example, and use SQL DISTINCT to remove duplicates. Then deal with the dummy values... Make sense?

  • lucywo
    lucywo Member

    vote for this answer.

     

    Nulls --> unique dummy -->remove duplicates --> you can convert back to null