mysql中查询字段为null或者不为null

  在mysql中,查询某字段为空时,切记不可用 = null或 !=null

如以下语句是错的,不会查出该字段为空的记录

 

select * from table where column != null;

正确应该为


select * from table where column is not null;