LookupCube (MDX)

Returns the value of a Multidimensional Expressions (MDX) expression evaluated over another specified cube in the same database.

Syntax

Numeric expression syntax
LookupCube(Cube_Name, Numeric_Expression )

String expression syntax
LookupCube(Cube_Name, String_Expression )

Arguments

  • Cube_Name
    A valid string expression that specifies the name of a cube.
  • Numeric_Expression
    A valid numeric expression that is typically a Multidimensional Expressions (MDX) expression of cell coordinates that return a number.
  • String_Expression
    A valid string expression that is typically a valid Multidimensional Expressions (MDX) expression of cell coordinates that returns a string.

Remarks

If a numeric expression is specified, the LookupCube function evaluates the specified numeric expression in the specified cube and returns the resulting numeric value.

If a string expression is specified, the LookupCube function evaluates the specified string expression in the specified cube and returns the resulting string value.

The LookupCube function works on cubes within the same database as the source cube on which the MDX query that contains the LookupCube function is running.

Important

You must provide any necessary current members in the numeric or string expression because the context of the current query does not carry over to the cube being queried.

See Also

Reference

MDX Function Reference (MDX)

Help and Information

Getting SQL Server 2005 Assistance

Change History

Release History

17 July 2006

Changed content:
  • Updated syntax and arguments to improve clarity.