mysql判断字段值是否为NULL
当我们想在sql语句中已某字段的值是否为null为条件进行查询,使用name = NULL 是不起作用的,
我们可以使用is null 和is not null 来判断某字段的值是否为null
select * from table where name is null
版权声明:本文为wydchn原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
当我们想在sql语句中已某字段的值是否为null为条件进行查询,使用name = NULL 是不起作用的,
我们可以使用is null 和is not null 来判断某字段的值是否为null
select * from table where name is null