RANK
Description:
This function is used to return the one-based rank of a specified tuple in a specified set.
Syntax:
Rank(Tuple_Expression, Set_Expression [ ,Numeric Expression ] )
Return type:
SCALAR
Parameters:
Parameter | Description |
|---|---|
Tuple_Expression | It is a valid MDX expression that returns a member. |
Set_Expression | It is a valid MDX expression that returns a set. |
Numeric_Expression | It is a valid numeric expression, typically an MDX expression of cell coordinates that returns a number. |
Example:
with MEMBER [Measures].[Rank] AS
Rank ([Customer].[Geography].CurrentMember,[Customer].[Geography].[City])
SELECT [Measures].[Rank] ON 0 ,
[Customer].[Geography].[City] ON 1
FROM [AdventureWorksMF]