oracle中表示“不等于”的有
!=
<>
~=
^=
都可以表示等于
但是,执行select * from 表名 t where t.name != ‘li’
时,
当 name 为 null 时,并不会显示,这是因为 null 与其他条件不同,
与 null 有关的语句为,is null
和is not null
如果你想要查询到所以的数据,需要改为
select * from 表名 t where t.name != ‘li’ or t.name is null
查询的时候null 并不会显示
oracle不等于
最新推荐文章于 2023-04-14 22:47:47 发布