!=和<>有什么区别?操作员? [英] What is the difference between != and <> operators?

查看:116
本文介绍了!=和<>有什么区别?操作员?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不喜欢不知道这一点,因为在某些情况下我需要使用一种而不是另一种。似乎在大多数情况下它们会产生相同的结果,但我猜测它们之间有细微的差别,也许与NULL值有关,或者像PHP中的extra =那样进行严格的比较。

I don;t like not knowing this as there may be situations when I need to use one instead of the other. It seems in most cases they produce the same results but I am taking a guess they have subtle difference, maybe to do with NULL values or one does strict comparisons like the extra = in PHP does.

谢谢

推荐答案

来自手册


注意:!=运算符在解析器阶段转换为<>。不可能实现!=和<>运算符来执行不同的操作。

Note: The != operator is converted to <> in the parser stage. It is not possible to implement != and <> operators that do different things.

因此,没有,两者之间没有区别两个。

So no, there is no difference between the two.

这篇关于!=和&lt;&gt;有什么区别?操作员?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆