MySQL判断字段是否为Null

admin 阅读:81 2024-03-03

查询mysql数据库表中字段为null的记录:


select * from 表名 where 字段名 is null

示例:


select * from student where address is null

查询mysql数据库表中字段不为null的记录:


select * from 表名 where 字段名 is not null

示例:


select * from student where address is not null
声明

1、部分文章来源于网络,仅作为参考。
2、如果网站中图片和文字侵犯了您的版权,请联系1943759704@qq.com处理!