Unary minus: - : Arithmetic Operators « Math Numeric Functions « MySQL Tutorial






This operator changes the sign of the argument.

mysql>
mysql> SELECT -2;
+----+
| -2 |
+----+
| -2 |
+----+
1 row in set (0.02 sec)

mysql>








21.2.Arithmetic Operators
21.2.1.Addition: +
21.2.2.Subtraction: -
21.2.3.Using Arithmetic Operators in select statement
21.2.4.Unary minus: -
21.2.5.Multiplication: *
21.2.6.Division by zero produces a NULL result
21.2.7.Division: /