Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a diagram where I use Time(class(MinStartTime, '00:15:00')) as an Dimension and the function is count(ID). Everything works. But know I need an easy KPI which gives me back the min count of ID´s in 15 minutes Intervals. But when I write down the expression
min(aggr(count(ID), Time(class(MinStartTime, '00:15:00')), Datum))
the Kpi gives back only -
Why?
Where is the mistake?
Thank you
You can't use calculated dimensions as an aggr() function dimension. In your case, I think it would be best to create a field in the data model
LOAD
Time(class(MinStartTime, '00:15:00')) as MinStartTimeClass,
...
and use this field in the chart as well as the aggr() dimension.
I don't think Aggr can take calculated dimensions -> min(aggr(count(ID), Time(class(MinStartTime, '00:15:00')), Datum)) and secondly do you want a single value in your KPI box or multiple values???
You can't use calculated dimensions as an aggr() function dimension. In your case, I think it would be best to create a field in the data model
LOAD
Time(class(MinStartTime, '00:15:00')) as MinStartTimeClass,
...
and use this field in the chart as well as the aggr() dimension.
The aggregation fields must be dimension fields, that is you cannot use an expression.
To be clear, try to use the expression Time(class(MinStartTime, '00:15:00')) as a dimension an see the result.
let me know
Only a single value... The result for the expression Min... must be 3!
And there is no possibilty to become this result?
Like Stefan mentioned below, calculate the dimension in the script and then use it in your aggregate function.