Selecting where row value is null
By Jamsi • Dec 8th, 2006 • Category: SQLDon’t ask me why, but I ALWAYS forget how to select results from an mSQL database where the value is null. It’s just weird.
I always try
select * from table where colname = null
or
select * from table where colname = ”
But the correct way is to select using IS NULL!
select * from table where colname IS NULL
No related posts.
FREE NEWSLETTER -> Want Tech Tips Sent Straight to your Inbox?
Grab our Newsletter to Ensure your PC is Running Smooth!
Jamsi is currently studying a full time Bachelor of Computer/Business degree and working part time as an Internet Security Consultant.
Email this author | All posts by Jamsi























