It looks like it was a string named NULL posing as a null value. I got 0 for ISNULL(suffix), which I assume means false. I tried this command ...
update persons set suffix = 'Empty' where suffix = ''; It changed the NULLs to Empty. On Mon, 2007-04-30 at 18:12 -0700, Jeremy Cole wrote: > Hi John, > > Are you sure they are actually NULL and not "NULL" (i.e. the string "NULL")? > > Try this: > > SELECT first, last, ISNULL(suffix), LENGTH(suffix) FROM persons LIMIT 5; > > Regards, > > Jeremy > > John Kebbel wrote: > > I'm having problems understanding NULL. I grasp what a NULL value is, > > but I can't get NULL to perform correctly. For instance, if I do a > > Select statement, I see that I have columns with a NULL value. > > > > select first, last, suffix from persons LIMIT 5; > > +-----------+----------+--------+ > > | first | last | suffix | > > +-----------+----------+--------+ > > | Benjamin | Page | NULL | > > | Jonathan | Watson | NULL | > > | Jose | Thorson | NULL | > > | Alejandro | Nickels | NULL | > > | Griselda | Richards | NULL | > > +-----------+----------+--------+ > > 5 rows in set (0.01 sec) > > > > Logically, it seems that a Select statement should find these five plus > > any other NULL values in the suffix column. However, such a select > > statment returns an empty set. > > > > mysql> select first, last, suffix from persons where suffix IS NULL; > > Empty set (0.00 sec) > > > > Does anyone see what I'm doing wrong? (Thanks in advance for any help.) > > > > > > > > > -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]