Is there any simple function in TSQL that could replace the below tsql?
SELECT * FROM Users
WHERE (Username IS NULL OR Username != @username)
I could write the below but that's not bullet proof due to the hard coded text!
SELECT * FROM Users
WHERE ISNULL(Username, 'dummytext') != @username
Thanks,