Re: MDX Help

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Lawrence,

Based on your description I am assuming you would like to build a set:
Monday, Tuesday and do not include last day of the week that is Wednesday.
Try to build your set following this logic: <MemberFrom>:<MemberTo>
Example from AdventureWorks. Easier to show at month level, This will return
years 2004 January to : July, even we have data in August.
SELECT
{OpeningPeriod([Date].[Calendar].[Month], [Date].[Calendar].[Calendar
Year].&[2004])
: ClosingPeriod([Date].[Calendar].[Month], [Date].[Calendar].[Calendar
Year].&[2004]).PrevMember
} ON 0
FROM [Sales Summary]
WHERE ([Measures].[Sales Amount])
;

Vidas Matelis
WebLog: http://www.ssas-info.com/content/blogcategory/14/36/






I am assuming that in your description
"Lawrence" <Lawrence@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:3271B6EF-E953-49AE-B187-EB2017D9D094@xxxxxxxxxxxxxxxx
Hello,

I have the following MDX Complication.

Goal - Return on the members UP TO the current day of the week. ie Today
is
Wednesday. I want to return all members Monday-Wednesday.

I currently have a Time.Test.[Current Day of Week] to find the current Day
of Week tuple.

Tail(Filter([Time].test.[day In week].Members,NOT IsEmpty([Time].test.[day
In week].CurrentMember)),1).Item(0)

Below is my [Previous Week] tuple. Is there a way to limit the member set
to only include members up to the current day of the week?

Tail(Filter([Time].[Week].Members,NOT
IsEmpty(Time.Week.CurrentMember)),1).Item(0).Lag(1)

Any help is much appreciated!

-Lawrence



.



Relevant Pages

  • NucleusCMS 3.01 SQL Injection Vulnerability
    ... // Nucleus CMS is a weblog php+mysql application. ... // This Proof of Concept dumps the username and MD5of the admin user placed at first position ... // of members table. ... else die("It doesn't :-(\n\n"); ...
    (Bugtraq)
  • Re: MDX Help
    ... What you should be looking is last day in time dimension, ... "Vidas Matelis" wrote: ... FROM [Sales Summary] ... Goal - Return on the members UP TO the current day of the week. ...
    (microsoft.public.sqlserver.olap)
  • Re: MDX in Cube Calculations
    ... Tuple is when you have multiple members from different attributes. ... Vidas Matelis ... If you have 10 members in a dimension and you want to create a set of the middle 4 how can you define the tuple with the syntax 1st and last for the set. ... I do not want to specify the middle members but just the range. ...
    (microsoft.public.sqlserver.olap)