GREATEST
Use GREATEST to return the highest value from a list of arguments. The data type of the result is based on the data type of the arguments.
Syntax
GREATEST(argument1, argument2, argument3)
Use GREATEST to return the highest value from a list of arguments. The data type of the result is based on the data type of the arguments.
GREATEST(argument1, argument2, argument3)