MySQL Tutorial/Comparison Functions Operators/Equal

Материал из SQL эксперт
Перейти к: навигация, поиск

Equal: =

mysql>
mysql> SELECT 1 = 0;
+-------+
| 1 = 0 |
+-------+
|     0 |
+-------+
1 row in set (0.00 sec)
mysql>
mysql>


SELECT "0.

mysql>
mysql>
mysql>
mysql> SELECT "0.0" = 0;
+-----------+
| "0.0" = 0 |
+-----------+
|         1 |
+-----------+
1 row in set (0.00 sec)


SELECT "0.

mysql>
mysql> SELECT "0.01" = 0;
+------------+
| "0.01" = 0 |
+------------+
|          0 |
+------------+
1 row in set (0.00 sec)


Type conversion when using the Equal operator

mysql>
mysql> SELECT "1" = 1;
+---------+
| "1" = 1 |
+---------+
|       1 |
+---------+
1 row in set (0.00 sec)