dbTalk Databases Forums  

Mixing cubes with oned MDX statement

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


Discuss Mixing cubes with oned MDX statement in the microsoft.public.sqlserver.olap forum.



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

Default Mixing cubes with oned MDX statement - 12-16-2004 , 02:36 AM






Hi

Is there any reason why I shouldn't mix the cubes referred to in the
ORDER and FILTER parts of an MDX statement.

This query is ignoring the FILTER, but if I remove the ORDER part the
FILTER works.

I am wondering if there is a problems caused by the fact that the
FILTER is based on one cube, whilst the ORDER is based on another

The middle section {XFILTERBYLEVEL( {XSUBSETALL( [Product] )}, 0)}uses
MDX functions specific to a 3rd party product to retrive all leaf
elements in a product dimension.

{ ORDER( {FILTER( {XFILTERBYLEVEL( {XSUBSETALL( [Product] )},
0)},[XProductScore].([Data].[SALES],[Variable Type].[% +/- Budget]) >
0.000000)}, [Category Plan].([Variable Type].[% +/- Budget],[Cost
Type].[Retail],[Version].[Actual
TY],[Data].[SALES],[Time].[05/06-W05]), BDESC) }

Regards

John

Reply With Quote
  #2  
Old   
Brian Altmann
 
Posts: n/a

Default RE: Mixing cubes with oned MDX statement - 12-16-2004 , 09:27 AM






MDX queries are restricted to a single cube. The only way to include data
from other cubes is to use the LookupCube function.
As an alternative, you can build a virtual cube.
HTH,
Brian
www.geocities.com/brianaltmann/olap.html


"John Hobson" wrote:

Quote:
Hi

Is there any reason why I shouldn't mix the cubes referred to in the
ORDER and FILTER parts of an MDX statement.

This query is ignoring the FILTER, but if I remove the ORDER part the
FILTER works.

I am wondering if there is a problems caused by the fact that the
FILTER is based on one cube, whilst the ORDER is based on another

The middle section {XFILTERBYLEVEL( {XSUBSETALL( [Product] )}, 0)}uses
MDX functions specific to a 3rd party product to retrive all leaf
elements in a product dimension.

{ ORDER( {FILTER( {XFILTERBYLEVEL( {XSUBSETALL( [Product] )},
0)},[XProductScore].([Data].[SALES],[Variable Type].[% +/- Budget])
0.000000)}, [Category Plan].([Variable Type].[% +/- Budget],[Cost
Type].[Retail],[Version].[Actual
TY],[Data].[SALES],[Time].[05/06-W05]), BDESC) }

Regards

John


Reply With Quote
  #3  
Old   
John Hobson
 
Posts: n/a

Default Re: Mixing cubes with oned MDX statement - 12-16-2004 , 09:41 AM



Many thanks Brian

Regards

John

Brian Altmann wrote:

Quote:
MDX queries are restricted to a single cube. The only way to include
data from other cubes is to use the LookupCube function.
As an alternative, you can build a virtual cube.
HTH,
Brian
www.geocities.com/brianaltmann/olap.html


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.