==null and is null are always mistaken, now summarize the mistakes you have encountered in your work.
1, at the time of inquiry
Select * from user where name is null;
< Span class= "Sql1-space" > select * from user where name is not null
< Span class= "Sql1-space" > 2, when updated
< Span class= "Sql1-reservedword" > < Span class= "Sql1-space" >update user set name = Null < Span class= "Sql1-space" >where id = 1
< Span class= "Sql1-space" > < Span class= "Sql1-symbol" >3 , count (1) and limit cannot use
< Span class= "Sql1-reservedword" > < Span class= "Sql1-space" >< Span class= "Sql1-space" >< Span class= "Sql1-space" > select count (1) from user where Name is not null limit 1;
Returns the number of users whose names cannot be empty, It has nothing to do with limit
4 scene: Each user has a note attribute, now find out the note is not" add a meal "user (including not filled in the note), this note by default is empty , There are several options: "Add a Meal" to add spicy" less oil"
select * from user where ifnull(remark, ‘‘ ") != "加一份饭 "
Note: If you write this:Select * from User where remark ! = "plus one meal " Span class= "Sql1-symbol",
so you'll only find records of "spicy" and "low-oil".
is null and = NULL in MySQL