dbTalk Databases Forums  

Calculated Measure , how to get

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


Discuss Calculated Measure , how to get in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Amish Manubhai Shah
 
Posts: n/a

Default Calculated Measure , how to get - 01-08-2005 , 12:23 AM






Hi, All Gurus

I am stuck on one problem for Calculated Measure
Any help will be very important for me.

For a simple cube I have one cube with 1 Dimension and 1 Fact tables

The Diemension is parent child.
id parent id name
1 enterprise 1
2 1 team1
3 2 Agent 1
4 2 Agent 2

so the dimension will like this

entreprise1
-team1
-Agent1
-Agent2

Fact Table is Like This

Id VALUE DATA

1 240
2 230
3 110 100
4 110 100

The Calculated measure we will get from the field VALUE

I want the cube like this

Goal (Calulated Measure from
VALUE) DATA
Ent Team Agent1 110
100
Agent 2 110
100
Total 230 ---- Goal for Team 1 Only
( Not From Agent1, Agent2 ) 200 (sum of Agent1
&Agent2)
Total 240 -------Goal for
Enterprise 1 Only (Not From Team1, Agent1, Agent2) 200(sum of Team)
--

Thanking You

Amish M Shah
Sr. Programmer
IntraAction Software(Ahmedabad, India)
Mo - 9879398697



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

Default Re: Calculated Measure , how to get - 01-08-2005 , 11:53 PM






Since the fact table has "Value" data for non-leaf members, presumably
the "Members With Data" option has been selected for your dimension. In
that case, assuming there is a basic Sum measure called "MyValue", then
the "Goal" can be:

Quote:
With Member [Measures].[Goal] as
'([MyDimension].CurrentMember.DataMember,
[Measures].[MyValue])'
Quote:

- Deepak

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!


Reply With Quote
  #3  
Old   
Amish Manubhai Shah
 
Posts: n/a

Default Re: Calculated Measure , how to get - 01-09-2005 , 11:04 PM



Thanks Deepak


"Deepak Puri" <deepak_puri (AT) progressive (DOT) com> wrote

Quote:
Since the fact table has "Value" data for non-leaf members, presumably
the "Members With Data" option has been selected for your dimension. In
that case, assuming there is a basic Sum measure called "MyValue", then
the "Goal" can be:


With Member [Measures].[Goal] as
'([MyDimension].CurrentMember.DataMember,
[Measures].[MyValue])'



- Deepak

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!



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.