在oracle中判断字段id不是“123”时, select * from user where id ‘123‘; 但是id为空的,却怎么也查询不出来。 原因是:字段为null的时候,只能通过is null或者is n
在oracle中判断字段id不是“123”时,
select * from user where id<> ‘123‘; 但是id为空的,却怎么也查询不出来。
原因是:字段为null的时候,只能通过is null或者is not null来判断。
这样写才是正确的: select * from user where id <> ‘123‘ or id is null;
Left join的on后条件不起作用的原因
on 后面的条件只能起链接俩个表的作用,不能作为过滤条件使用,过滤条件只能加在where 后面
Oracle中“不等于”的使用
--结束END--
本文标题: Oracle中“不等于”的使用
本文链接: https://www.lsjlt.com/news/7909.html(转载时请注明来源链接)
有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341
下载Word文档到电脑,方便收藏和打印~
2024-05-07
2024-05-07
2024-05-07
2024-05-07
2024-05-03
2024-05-03
2024-05-03
2024-05-03
2024-05-03
2024-05-03
回答
回答
回答
回答
回答
回答
回答
回答
回答
回答
0