15. 2. 1. expr BETWEEN min AND max |
|
expr NOT BETWEEN min AND max is the same as NOT (expr BETWEEN min AND max). |
If expr is greater than or equal to min and expr is less than or equal to max, BETWEEN returns 1. |
Otherwise it returns 0. |
This is equivalent to the expression (min <= expr AND expr <= max). |
mysql>
mysql> SELECT 1 BETWEEN 2 AND 3;
+-------------------+
| 1 BETWEEN 2 AND 3 |
+-------------------+
| 0 |
+-------------------+
1 row in set (0.00 sec)
mysql>
|
|