No function matches signature 'Time(<DateTime>)'

Hi All,

I am trying to get the version release start date from a certain date and also I want to aggregate priority, below is my formula

CASE
when [Release Version].CurrentMember.StartDate > “2023-01-01”
then Aggregate({
[Priority].[Critical]
})
END

I am getting below error

Formula is not valid:
No function matches signature ‘Time()’

Hi @agudipelli,

If you want to perform calculations involving multiple dimensions, the calculation should happen in the “Measures” to ensure consistency and avoid unpredictable results in combinations with different other measures.

Although, the .StartDate is a convenient function - it only works for the Time dimension. Please read more about that here - StartDate.

The “Start Date” property of the current member from the “Release Version” dimension could be retrieved via the following expression.

[Release Version].CurrentHierarchyMember.Get("Start Date")

Since the Time has a specific data format, it requires a specific function for comparison. Please read more about Datecompare() here - DateCompare.

If you want to compare a specific date against the current Release Version start date, the expression might be as follows.

Datecompare(
[Release Version].CurrentHierarchyMember.Get("Start Date"),
"2023-01-01")

The total expression for finding the number of issues with “Critical” priority when the current Release Version start date is after “2023-01-01” might look as follows.

CASE WHEN
 DateCompare(
  [Release Version].CurrentHierarchyMember.Get("Start Date"),
  "2023-01-01") >0
THEN
Sum({[Priority].[Critical]},
 [Measures].[Issues created])
END

Regards,
Oskars / support@eazyBI.com