MySQL里想查询name这个字段不为空的SQL where 条件 怎么写?

如题所述

where (name is not null or name<>'')

正常的话只用name is not null就好,但是不排除有空字符的情况,所以用上边比较稳妥
温馨提示:内容为网友见解,仅供参考
第1个回答  2013-11-04
select * from 表名 where name is not null
相似回答