max()

Returns the maximum value of the given expression. It ignores any expression that is null.

Syntax

max(NUM_EXPR, ...)
Required Parameters
NUMBER, ...
Expression list that returns int, short, long, float, or double

Usage

json "{}" | eval max=max(1) => 1

json "{}" | eval max=max(1, 2) => 2

json "{}" | eval max=max(1, 2, null) => 2

json "{}" | eval max=max(null) => null