dbTalk Databases Forums  

calcuated memeber

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


Discuss calcuated memeber in the microsoft.public.sqlserver.olap forum.



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

Default calcuated memeber - 02-22-2006 , 03:31 PM






I have a time analysis utility dimension called Period that has a member of
current. I created a few calculated members such as MTD, YTD, QTY, YearTtl,
MonthTtl. I also have 5 measures: M1, M2, M3, M4, M5. The time dem is Year,
Month, Day.

How do I create a calculated member that is:

(MTD of M1)/(MonTtl of (M1 + M2 + M3 + M4))
(YTD of M1)/(YearTtl of (M1 + M2 + M3 + M4))

Thanks for any help.


Reply With Quote
  #2  
Old   
christy
 
Posts: n/a

Default RE: calculated memeber - 02-22-2006 , 07:49 PM






Do I need two calculated members for that?
Any thoughts, please.

"christy" wrote:

Quote:
I have a time analysis utility dimension called Period that has a member of
current. I created a few calculated members such as MTD, YTD, QTY, YearTtl,
MonthTtl. I also have 5 measures: M1, M2, M3, M4, M5. The time dem is Year,
Month, Day.

How do I create a calculated member that is:

(MTD of M1)/(MonTtl of (M1 + M2 + M3 + M4))
(YTD of M1)/(YearTtl of (M1 + M2 + M3 + M4))

Thanks for any help.


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

Default RE: calculated memeber - 02-22-2006 , 10:31 PM



You could implement it as a single calculated measure, depending on how
you determine which of the 2 expressions to use - is it based on the
level of [Time].CurrentMember?


- Deepak

Deepak Puri
Microsoft MVP - SQL Server

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

Reply With Quote
  #4  
Old   
christy
 
Posts: n/a

Default RE: calculated memeber - 02-23-2006 , 02:39 PM



Yes. It is based on [Time].CurrentMember

If the currementmemeberis 02/23/2006 then

MTD(02/01/06 to 02/23/06) of M1 divided by MonthTtl(whole month of 02/2006)
of (M1 + M2 + M3 + M4).




"Deepak Puri" wrote:

Quote:
You could implement it as a single calculated measure, depending on how
you determine which of the 2 expressions to use - is it based on the
level of [Time].CurrentMember?


- Deepak

Deepak Puri
Microsoft MVP - SQL Server

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


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

Default RE: calculated memeber - 02-23-2006 , 05:00 PM



Then try this calculated measure expression:

Quote:
Sum({[Time].FirstSibling:[Time].CurrentMember},
[Measures].[M1]) /
Sum({[Time].Parent},
[Measures].[M1] + [Measures].[M2]
+ [Measures].[M3] + [Measures].[M4])
Quote:

- 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.