dbTalk Databases Forums  

union two cube results

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss union two cube results in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Tomas
 
Posts: n/a

Default union two cube results - 11-08-2005 , 01:30 PM






I want to union two cubes results into one. Below is one of the mdx
SELECT {[Measures].[Current Year Target],[Measures].[Actual Revenue],
[Measures].[Revenue],[Measures].[MTD %] ,[Measures].[YTD Actual]
,[Measures].[YTD Goal] , [Measures].[YTD %] } ON COLUMNS ,
NON EMPTY CROSSJOIN(
[DistrictIsManaged].[District Id].members,
[Territory].[Territory Desc].members
) ON
ROWS
FROM [Sales vs RepBudget]
WHERE ([Time].[All Time].[2005].[Quarter
1].[January],[RegionIsManaged].[Region Id].[East])

Second Cube is Sales vs SalesBudget, because they are look at different
budget dimensions
SELECT {[Measures].[Current Year Target],[Measures].[Actual Revenue],
[Measures].[Revenue],[Measures].[MTD %] ,[Measures].[YTD Actual]
,[Measures].[YTD Goal] , [Measures].[YTD %] } ON COLUMNS ,
NON EMPTY( [DistrictGeo].[District Id].members
) ON
ROWS
FROM [Sales vs SalesBudget]
WHERE ([Time].[All Time].[2005].[Quarter 1].[January],[RegionGeo].[Region
Id].[East])

As you can see, the first mdx will return district break with its territory,
while the second will return district with its totals

I tryied to cread a virtual cube , that will contain both SalesBudget and
RepBudget, but could not do it, since One Budget will go down to the
territory, while the other will go to the district, and the data is not the
same for both.

thank you



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.