Function documentationGREATEST/LEAST(x,y,...) Locate this document in the navigation structure

 

GREATEST(x,y,...) or LEAST(x,y) is a special function that calculates the maximum or minimum value of all arguments (expressions).

The functions can be applied to any data type. The data types of the individual expressions must be comparable.

GREATEST/LEAST(x,y,...)

x, y, ...

Result of the Function

At least one argument is the NULL value

NULL value

At least one argument is the special NULL value

Special NULL value