Well, it's not clear from the query why PeriodsToDate() is needed (if,
indeed, you're simply trying to sum the measure over the specified date
range). The optional 2nd argument for PeriodsToDate() should be a
member, not a range:
http://msdn2.microsoft.com/en-us/library/ms144925.aspx
Quote:
|
SQL Server 2005 Books Online
|
PeriodsToDate (MDX)
Returns a set of sibling members from the same level as a given member,
starting with the first sibling and ending with the given member, as
constrained by a specified level in the Time dimension.
Syntax
PeriodsToDate( [ Level_Expression [ ,Member_Expression ] ] )
...
So, something like this might suffice:
Round(Sum(
{[Time].[2006].[Q2].[May].[17]
:[Time].[2006].[Q3].[July].[25]},
[Measures].[Actual Work]), 0)
- Deepak
Deepak Puri
Microsoft MVP - SQL Server
*** Sent via Developersdex http://www.developersdex.com ***