dbTalk Databases Forums  

Analysis Services - Median Calculation

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


Discuss Analysis Services - Median Calculation in the microsoft.public.sqlserver.olap forum.



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

Default Analysis Services - Median Calculation - 03-03-2005 , 09:47 PM






A really simple question,,,, I need to calculate the median of a
Quote:
measure. I'm having a tough time to figure out which dimension to use.
If If I have 4 dimensions, Date, region, site, and process code and I
want to get the median for the measure number of days, what do I use to
define the set?

median ([Process].AllMembers,measures.[No Of Days]) this is not working,
but at least the syntax was clean

standard median prompt
Median («Set»[, «Numeric Expression»])

As I select different subsets of region, site and process code I
obviously want the median of No of days to be dynamic.

Stuck here and waiting anxiously for some bright person to shed the
light!!!

thanks,,,


Reply With Quote
  #2  
Old   
Ohjoo Kwon
 
Posts: n/a

Default Re: Analysis Services - Median Calculation - 03-03-2005 , 10:06 PM






I'm not sure that I understand what you want rightly, but I guess you need
StrToSet(). For example,

Median(StrToSet("Axis(1)").Item(0).Item(0).Dimensi on.AllMembers, [No Of
Days])

Ohjoo Kwon


"Peter" <Peter (AT) discussions (DOT) microsoft.com> wrote

Quote:
A really simple question,,,, I need to calculate the median of a
measure. I'm having a tough time to figure out which dimension to use.
If If I have 4 dimensions, Date, region, site, and process code and I
want to get the median for the measure number of days, what do I use to
define the set?

median ([Process].AllMembers,measures.[No Of Days]) this is not working,
but at least the syntax was clean

standard median prompt
Median (¡ìSet¡í[, ¡ìNumeric Expression¡í])

As I select different subsets of region, site and process code I
obviously want the median of No of days to be dynamic.

Stuck here and waiting anxiously for some bright person to shed the
light!!!

thanks,,,




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.