oracle查询语句注意事项:
发布时间:2020-12-12 13:25:56 所属栏目:百科 来源:网络整理
导读:我想查出 datatype 不等于1的所有结果,包括空。 select * from user where datatype ‘ 1 ‘ ; // 这条sql查不出 datatype为空的数据 ?发现oracle需要使用? is? null? 、is? not null查询空或非空 select * from user where datatype ‘ 1 ‘ or datatype i
我想查出datatype 不等于1的所有结果,包括空。 select * from user where datatype <> ‘1‘; //这条sql查不出datatype为空的数据 ?发现oracle需要使用? is? null? 、is? not null查询空或非空 select * from user where datatype <> ‘1‘ or datatype is null;//这样就能查出datatype不等于1的所有结果
? ------------------------------------------------------------------------------------------------------------------------------------ (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |