/
AGGREGATE

AGGREGATE

Description:

This function is used to return a number that is calculated by aggregating over the cells returned by the set expression. If a numeric expression is not provided, this function aggregates each measure within the current query context by using the default aggregation operator that is specified for each measure. If a numeric expression is provided, this function first evaluates, and then sums, the numeric expression for each cell in the specified set.

Syntax:

Aggregate(Set_Expression [ ,Numeric_Expression ])

Return Type:
SCALAR

Parameters:

Parameter

Description

Parameter

Description

Set_Expression

It is a valid MDX expression that returns a set.

Numeric_Expression

A valid numeric expression is typically an MDX expression of cell coordinates that returns a number.

Example:

WITH MEMBER [Measures].[DC] AS Aggregate( [Customer].[Geography].[Country].&[Australia], [Customer].[Geography].[Country].&[Canada] ) SELECT [Measures].[DC] ON COLUMNS, [Product].[Product Categories].Children ON ROWS FROM [AdventureWorksMF]

Related content

AVG
More like this
ADDCALCULATEDMEMBERS
ADDCALCULATEDMEMBERS
More like this
CROSSJOIN
CROSSJOIN
More like this
CURRENTMEMBER
CURRENTMEMBER
More like this
COUNT
More like this
ALLMEMBERS
ALLMEMBERS
More like this

Copyright Kyvos, Inc. All rights reserved.