September 2002
Intermediate to advanced
1024 pages
30h 52m
English
LEAST
LEAST takes one or more strings as input and returns the string that would come first (i.e., that is the least) if the inputs were to be sorted in ascending order. The ordering of the strings is based on character code in the database character set. LEAST has the following specification:
FUNCTION LEAST (string1 IN VARCHAR2, string2 IN VARCHAR2,...) RETURN VARCHAR2
Following is an example:
BEGINDBMS_OUTPUT.PUT_LINE(LEAST('Gennick','Pribyl','Feuerstein'));END;Feuerstein
Also see the GREATEST function, which is the opposite of LEAST.
Read now
Unlock full access