dbTalk Databases Forums  

trouble applying PeriodstoDate

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


Discuss trouble applying PeriodstoDate in the microsoft.public.sqlserver.olap forum.



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

Default trouble applying PeriodstoDate - 10-10-2005 , 02:25 AM






Hi. I am building a cube in visual studio beta 2,april ctp.
i'm new at using it.

I am finding troubles applying the periodstodate function to my mdx calculated member. it's not giving me the desired result. i'm applying with it the avg function however at every member it's giving me the exact value of the measure at that member. for example:
AY 0405, term 1, week 1 :measure= 40, periods to date = 40
AY 0405, term 1, week 2 :measure= 20, periods to date = 20 (should be 30).

in the beginning, the dimension type of the time dimension was "regular". i then put it as "time" but still the result is the same.

this is my formula:
avg(periodstodate([dates].[weeks].[week],[dates].[weeks].prevmember),[measures].[att_index])
where att_index is the measure involved and the time dimension called "dates" has a hierarchy called "weeks" and in it i have 3 levels : acad year, term,and week.
Please tell me if the formula is wrong or if i missed a property for this dimension or if there is a formula that could give me the same result.


many thanks
Christina

************************************************** ********************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...

Reply With Quote
  #2  
Old   
 
Posts: n/a

Default Re: trouble applying PeriodstoDate - 10-10-2005 , 07:49 AM






hi. it's me again. it worked. instead of putting [dates].[weeks].[week] in the function i should have put [dates].[weeks].[term].

thanks anyway
Christina

************************************************** ********************
Sent via Fuzzy Software @ http://www.fuzzysoftware.com/
Comprehensive, categorised, searchable collection of links to ASP & ASP.NET resources...

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.