在mysql中,查询空和非空不是简单的"==null"或"!=null"
mysql和我们常用的例如java,还是不一样的
要使用"is null"或是"is not null"
例如:
SELECT * FROM items i where i.item_name is NOT NULL
SELECT * FROM items i where i.item_name is NULL
在mysql中,查询空和非空不是简单的"==null"或"!=null"
mysql和我们常用的例如java,还是不一样的
要使用"is null"或是"is not null"
例如:
SELECT * FROM items i where i.item_name is NOT NULL
SELECT * FROM items i where i.item_name is NULL