Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
DB Engine
SQL ServerMSDESQL Server CE
Services
Analysis (Data Mining)Analysis (OLAP)DTSIntegration ServicesNotification ServicesReporting Services
Programming
CLRConnectivitySQLXML
Other Technologies
ClusteringEnglish QueryFull-Text SearchReplicationService Broker
General
Data WarehousingPerformanceSecuritySetupSQL Server ToolsOther SQL Server Topics
DirectoryUser Groups
Related Topics
MS AccessOther DB ProductsMS Server Products.NET DevelopmentVB DevelopmentJava DevelopmentMore Topics ...

SQL Server Forum / General / Data Warehousing / October 2005

Tip: Looking for answers? Try searching our database.

Help with MDX selecting multiple attributes in Where clause

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Steven - 18 Oct 2005 02:05 GMT
Given the following:

Dimension Name:          Issues

Measure:                       Issue Count

Dimension Attributes:     Priority (Values 1,2,3,4)

                                   Severity (Values 1,2,3,4)

How can I format an MDX statement to select Issues Where (Priority = 1 or
Priority = 2) and (Severity = 1 or Severity = 2)?

When I try the following:

select [Measures].[Issue Count] on columns,

([Time].[Date].&[9/18/2005]:[Time].[Date].&[10/17/2005]) on rows

From [Issues DB]

where

{

([Issues].[Priority].&[1]),([Issues].[Priority].&[2]),

([Issues].[Severity].&[1]), [Issues].[Severity].&[2]

}

I get the error referenced below:

"Members belong to different hierarchies in the  function."

Any pointers would be greatly appreciated!

~Steven
Word 2003 memory Leakage - 18 Oct 2005 14:09 GMT
I guess you treat Priority and Severity as same level and put them between
{}, which is for a set.

Try this:

(

{[Issues].[Priority].&[1], [Issues].[Priority].&[2]},

{[Issues].[Severity].&[1], [Issues].[Severity].&[2]}

)

In your case, I would say put these two properties in 2 hierarchies. which
may improve the performance.

Guangming

> Given the following:
>
[quoted text clipped - 34 lines]
>
> ~Steven
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.