Curriculum
Course: MYSQL
Login

Curriculum

MYSQL

MySQL References

0/140
Text lesson

LEAST

Example

Provide the minimum value from the list of arguments.

SELECT LEAST(312, 34825); 

Definition and Usage

The LEAST() function yields the smallest value from the list of arguments.

Note: Also consider the GREATEST() function.

Syntax

LEAST(arg1arg2arg3, …)

Parameter Values

Parameter

Description

arg1arg2arg3, …

Necessary: Specify the list of arguments for assessment.

Technical Details

Works in: From MySQL 4.0

More Examples

Example

Provide the minimum value from the given list of arguments.

SELECT LEAST(“w3Schools.com”“microsoft.com”“apple.com”);