Mega Code Archive
GREATEST(value1,value2, ) returns the largest (maximum-valued) argument within two or more arguments
mysql>
mysql> SELECT GREATEST(2,0);
+---------------+
| GREATEST(2,0) |
+---------------+
| 2 |
+---------------+
1 row in set (0.00 sec)
mysql>