Database Reference
In-Depth Information
Figure 14-8. A query that returns two tuples
Be careful not to identify the multiple members from the same dimension as coordinates for a tuple. When
you do so, you will receive an error. In Listing 14-13 you see that we are using two members, [Business] and
[Psychology], from the same [DimTitles].[TitleType] hierarchy. Running this query gives the error message
“The 'TitleType' hierarchy appears more than once in the tuple.”
Listing 14-13. Improper Coordinates for a Single Tuple
-- This query will not work!
Select
{
[Measures].[SalesQuantity]
, [Measures].[NumberOfSales]
} On Columns,
{ ( −- This parenthesis indicates you are defining multiple coordinates
-- for a SINGLE tuple (a.k.a. a result value )
[DimTitles].[TitleType].&[Business]
-- A second coordinate won't work if it is from the same dimension!
, [DimTitles].[TitleType].&[Psychology]
) } On Rows
From [CubePubsSales];
//Error = The 'TitleType' hierarchy appears more than once in the tuple.
-- This works though!
Select
{
[Measures].[SalesQuantity] -- 1st tuple
, [Measures].[NumberOfSales] -- 2nd tuples
} On Columns,
Search WWH ::




Custom Search