MAX

MAX returns the largest of a selection of data values calculated over a Time dimension.

Return Value

NUMBER

Syntax

MAX (value_expr) OVER HIERARCHY 
    ( [ dimension | hierarchy ]
	   BETWEEN start AND end [WITHIN relation]
    )

Arguments

value_expr is a dimensional expression whose values you want to calculate.

dimension is the Time dimension over which the values are calculated.

hierarchy is the Time hierarchy over which the values are calculated. Otherwise, the default hierarchy is used.

start and end are the boundaries of the calculation, which are expressed with one of these clauses:

relation can be any of the following:

Example

MAX(GLOBAL.UNITS_CUBE.UNITS) OVER HIERARCHY (GLOBAL.TIME BETWEEN 1 FOLLOWING AND 3 FOLLOWING WITHIN ANCESTOR AT LEVEL GLOBAL.TIME.YEAR)

Related Topics

AVG, COUNT, MIN, SUM