Min

The Min Function returns the minimum value out of a set of expressions.

Syntax :

MIN(Expression,[Value2])

Parameters :

Parameters Description
Expression The first value or range to consider when calculating the minimum value.
Value2 [OPTIONAL] - Additional values or ranges to consider when calculating the minimum value.

Examples :

Table Name : Products

ProductID Product Name Price
1 Pen 6
2 Pencil 3
3 Eraser 2
4 Bottle 5
5 Book 10

Example 1

dMin = Min(Price)
DEBUG(dMin)

Result :

dMin
= 2

Example 2

dMin = Min(10,5) 
DEBUG(dMin)

Result :

dMin
= 5