NullMoneyException
java.life.NullMoneyException

要给oracle某个字段插入空值非常简单

insert into table(column) values('')

 

但是查询的时候通过语句

select * from table where column ='';
select * from table where column =null;

查询是查不到结果的,因为表中column是没有内容的,不能直接使用‘’;

而null作为关键字也是不能用 = 来判断的,应该使用关键字 is 和 is not ;

select * from table where column is null;
select * from table where column is not null;

 

posted on 2017-11-28 09:33  NullMoneyException  阅读(2057)  评论(0编辑  收藏  举报