Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Newbie on MDX: How to use dimension as a query parameter? Expand / Collapse
Author
Message
Posted Monday, July 1, 2013 6:56 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Wednesday, July 3, 2013 3:21 AM
Points: 1, Visits: 7
 SELECT NON EMPTY {([Measures].[Agent - Prcnt Default AUX0]),
([Measures].[Table - Info A]),
([Measures].[Table - Info B]),
([Measures].[Table - Info C])} ON COLUMNS,
[Dim Employee Main].[Employees].[Employee] on rows
FROM ( SELECT ( STRTOMEMBER(@FromDimTimeDays, CONSTRAINED) : STRTOMEMBER(@ToDimTimeDays, CONSTRAINED) )
ON COLUMNS FROM ( SELECT ( STRTOSET(@DimEmployeeEmployeeRole, CONSTRAINED) )
ON COLUMNS FROM ( SELECT ( STRTOSET(@DimEmployeeLevelManager, CONSTRAINED) )
ON COLUMNS FROM ( SELECT ( STRTOSET(@DimBusinessAccounts, CONSTRAINED) )
ON COLUMNS FROM ( SELECT ( STRTOSET(@DimLocationSites, CONSTRAINED) )
ON COLUMNS FROM [Cube Table])))))



WHERE (


IIF( STRTOSET(@DimLocationSites, CONSTRAINED).Count = 1,
STRTOSET(@DimLocationSites, CONSTRAINED), [Dim Location].[Sites].currentmember ),

IIF( STRTOSET(@DimBusinessAccounts, CONSTRAINED).Count = 1,
STRTOSET(@DimBusinessAccounts, CONSTRAINED), [Dim Business].[Accounts].currentmember ),

IIF( STRTOSET(@DimEmployeeLevelManager, CONSTRAINED).Count = 1,
STRTOSET(@DimEmployeeLevelManager, CONSTRAINED), [Dim Employee].[Level 1 Manager].currentmember ),

IIF( STRTOSET(@DimEmployeeEmployeeRole, CONSTRAINED).Count = 1,
STRTOSET(@DimEmployeeEmployeeRole, CONSTRAINED), [Dim Employee].[Employee Role].currentmember ))

CELL PROPERTIES VALUE


Goal: To pull all employees all at once and to be able to pull a single employee profile.

However, I do not know how I can include the dimension Employees as a query parameter.
Post #1469037
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse