dbTalk Databases Forums  

Re: Sum in MDx expression

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


Discuss Re: Sum in MDx expression in the microsoft.public.sqlserver.olap forum.



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

Default Re: Sum in MDx expression - 10-04-2006 , 06:13 PM






Hi Yolanda,

Based on your problem description, one solution will be to create 2 cube
"sum" measures, rather than calculated measures, based on SQL
expressions like:

For order amount:

case when coalesce([Proceed].[Trip No.], '') = ''
then [Proceed].[Amount] else 0 end

For trip amount:

case when coalesce([Proceed].[Trip No.], '') <> ''
then [Proceed].[Amount] else 0 end


If you're using AS 2000, then these expressions can be added in a view,
or as the measure's "Source Column". WIth AS 2005, they can be addes as
Named Calculations.

- Deepak

Deepak Puri
Microsoft MVP - SQL Server

*** Sent via Developersdex http://www.developersdex.com ***

Reply With Quote
  #2  
Old   
Deepak Puri
 
Posts: n/a

Default Re: Sum in MDx expression - 10-05-2006 , 09:04 AM






There are many factors affecting cube processing time, so it's hard to
say without knowing more details. If you're using AS 2000 with many
dimensions, then cube schema optimization (which requires dimensions to
be shared) is highly recommended.


- Deepak

Deepak Puri
Microsoft MVP - SQL Server

*** Sent via Developersdex http://www.developersdex.com ***

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.