Re: behaviour of WHERE clause with empty fields

2002-11-01 Thread John Ragan
the manual indicates that "mysql follows ansi sql, and a comparison with null is always null". after years of server work, i still sometimes forget that, at least in all the servers that i've used, null and nothing are not the same thing. > >Description: > Empty fields are not matched

RE: behaviour of WHERE clause with empty fields

2002-11-01 Thread Fernando Grijalba
I think this is because a NULL is not and empty string. They are different things. to match NULL you got to do: WHERE grp IS NULL or to exclude NULL: WHERE grp IS NOT NULL. I think that NULL values are excluded from string comparisons. I might be wrong though! JFernando ** sql ** -Ori