Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Testing for IS NULL within query

Status
Not open for further replies.

monkey64

Technical User
Apr 27, 2008
69
GB
I have a database with some null values.
I understand that I should be able to use IS NULL within my query.

Code:
SELECT * FROM `mytable` WHERE  mycol IS NULL

From within PhpMyAdmin, I get this:
MySQL returned an empty result set (i.e. zero rows).

What am I doing wrong?
 
Actually, I just answewd my own question.
The value appeared NULL, but testing for "WHERE mycol = ''", showed the missing values.

So I learnt a lesson...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top