dbTalk Databases Forums  

Re: MDX calaulated measures

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


Discuss Re: MDX calaulated measures in the microsoft.public.sqlserver.olap forum.



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

Default Re: MDX calaulated measures - 07-02-2003 , 02:48 AM







Hi Sean,

Thanks for your replay, But I got a syntax error when
I tried to do this, I can't find the error, can you check
your expression and find the error?

chovi.


IIF(Products.CurrentMember.Level.Name="product name",
COUNT(FILTER(DESCENDANTS(Time.currentmember, Time.Days),
[Measures].[Sales]
Quote:
50)),
NULL)


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


Reply With Quote
  #2  
Old   
Sean Boon [MS]
 
Posts: n/a

Default Re: MDX calaulated measures - 07-02-2003 , 12:53 PM






You can try this in the MDX sample app.

with member Measures.[test] as

'IIF(Product.CurrentMember.Level.Name="product name",
COUNT(FILTER(DESCENDANTS(Time.currentmember, Time.Day),
[Measures].[Unit Sales]
Quote:
50)),NULL)'
select {[Measures].[Unit Sales]} on columns,
{[Product Name].members} on rows from SALES



You can also just use the first part before the SELECT statement as a
calculated member in your cube. Your dimension names might be different
than the ones in foodmart. You'll need to adjust the syntax for that.

Sean


--
Sean Boon
SQL BI Product Unit

**This posting is provided AS IS, with no warranties, and confers no
rights.**
"Chovav Mazor" <chovavm (AT) random-logic (DOT) com> wrote

Quote:
Hi Sean,

Thanks for your replay, But I got a syntax error when
I tried to do this, I can't find the error, can you check
your expression and find the error?

chovi.


IIF(Products.CurrentMember.Level.Name="product name",
COUNT(FILTER(DESCENDANTS(Time.currentmember, Time.Days),
[Measures].[Sales]
50)),
NULL)


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