min

Description

Returns the minimum value of a group of inputs.

Given one argument column, min computes the minimum of that column across a group of rows.

Given multiple columns, min computes the scalar least value of those columns across a group of rows. In this case, the function evaluates to null if any of the arguments evaluate to null.

Return type

least common generalization

Domain

This is an aggregate function (aggregates rows over a group in aggregate verbs.)

This is a window function (calculates over a group of multiple input rows using windowing.)

Categories

Usage

min(expression_1, expression_2, ...)

Argument

Type

Optional

Repeatable

Restrictions

expression

comparable

no

yes

none