Min

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

Syntax :

MIN(Expression,[Condition])
Parameters Description
Expression The first value or range to consider when calculating the minimum value.
Condition [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(Price, Price<>2) 
DEBUG(dMin)

Result :

dMin
= 3