NOT EQUAL Operator in SQL
NOT EQUAL Operator in SQL is used to compare two values and return if they are not equal.
This operator returns boolean values. If given expressions are equal, the operator returns false otherwise true. If any one expression is NULL, it will return NULL.
It performs type conversion when expressions are of different data types, for example, 5!= “Five”.
We use the NOT EQUAL operator to display our table without some exceptional values. For example, Let’s, consider a table ‘Students’. For this table, we have, “id”, “name”, and “marks” as its columns. Now we want to display all those rows that have marks not equal to “100”. In this kind of situation, the NOT EQUAL operator can be used.
Note: <> and != perform the same operation i.e. check inequality. The only difference between <> and != is that <> follows
the ISO standard but != does not. So it is recommended to use <> for NOT EQUAL Operator.
SQL NOT EQUAL Operator
SQL NOT EQUAL Operator is a comparison operator used to check whether two expressions are equal. This operator is represented by ” != ” or “<>“.
Contact Us