Hello,
Context:
- I need to sum the committed story points of the sprints started in every two weeks within a grace period.
- The [Time] dimension has the 2-week-based configuration, which starts on every other Wednesdays.
- The sprints should start on Weds, however, they may start with one day earlier or later.
- The report, which uses this information, has only the [Project] dimension on the rows. That is, no [Time] dimension is used.
- I created the custom calculation called [Measures].[CommittedSPs], which has a generic implementation for calculating the committed story points of sprints started with +/- 1 day difference compared to the Wed-s, which are the StartDate of each 2-week-long period.
- I need to see history on this, therefore, I am using the Lag() function too.
[Measures].[CommittedSPs]
Sum(
Filter(
[Sprint].[Sprint].Members,
DateBetween(
DateWithoutTime( [Sprint].CurrentMember.Get('Activated date') ),
DateWithoutTime( DateAddDays( [Time].CurrentHierarchyMember.StartDate, -1 ) ),
DateWithoutTime( DateAddDays( [Time].CurrentHierarchyMember.StartDate, 1 ) )
)
)
,
[Measures].[Sprint Story Points committed]
)
- The custom calculated measure would be instantiated with a specific time in the report. e.g.
(
[Measures].[CommittedSPs],
[Time.2 Weeks].[2 Weeks].CurrentDateMember.Lag(5)
)
- I am using SparkLineData with column mode to visualise the committed story points over time, therefore, I am using it the way below:
SparklineData(
LastPeriods(6, [Time.2 Weeks].[2 Weeks].CurrentDateMember.Lag(1))
,
[Measures].[CommittedSPs]
)
The issue
- The custom calculation [Measures].[CommittedSP] does not return value for a case, when the Sprint was started a day earlier compared to the Wed-s. However, the ‘-1’ condition should cover that case.
- The custom calculation returns correct data for other sprints. SparkLine has columns with the right values.
- If I use the code below, which basically selects explicitly a specific time, then the [Measures].[Sprint Story Points committed] returns a value.
Sum(
Filter(
[Sprint].[Sprint].Members,
DateBetween(
DateWithoutTime( [Sprint].CurrentMember.Get('Activated date') ),
DateAddDays( [Time.2 Weeks].[2 Weeks].CurrentDateMember.Lag(5).StartDate, -1 ),
DateAddDays( [Time.2 Weeks].[2 Weeks].CurrentDateMember.Lag(5).StartDate, 1 )
)
)
,
[Measures].[Sprint Story Points committed]
)
I have already debugged the sub parts, meaning
- The right date is selected
- The right date period is calculated
- The right sprints are identified
I ran out of ideas of why I see the difference results between the Custom Calculation and the manually instantiated one. However, they are using the same logic to filter for the sprints activated in the grace period (+/- 1 day)
Thank you for your help in advance,
Gyula