Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I want to count the maximum job run within a previous day of the specified date [Running date]
Below is my set analysis.
max(aggr(Count({<[Start 1h]={">00:00:00"},[Start 1h]={"<=23:00:00"}>}
distinct [Run Id & Job Name Key]),[Running Date Start 1h], [Running Date],[Project Name]))
But the result return the maximum run of specified date, not the previous date.
Would appreciate some guidance on this. many thanks.
Your syntax is not correct, maybe try this:
max(aggr(Count({<[Start 1h]={">00:00:00 <=23:00:00"}>}
distinct [Run Id & Job Name Key]),[Running Date Start 1h], [Running Date],[Project Name]))
Thanks a lot for your advice. It still does not change.
My formula objective is that if user chooses [Running Date]=31-Jul-2023
The Max count will return the result for [Running Date]=30-Jul-2023
Try this:
max(aggr(Count({<[Running Date]={“$(=Date(only([Running Date])-1))"}>}
distinct [Run Id & Job Name Key]),[Running Date Start 1h], [Running Date],[Project Name]))
Thank you again for your expert guidance. The result still gives the specified date count not the previous day
@43918084 What i see in your analysis expression you have used only Time format, But this will recognize the date 🙂 My best assumption to add dimension with full timestamp field to overcome this.
Is this field [Running Date] come from full timestamp?
Thanks a lot for your suggestion and guidance . I ve changed to below and still no change 🤔
=max(aggr(Count({<[Start 1h]={">00:00:00 <=23:00:00"}>+<[Running Date]={"$=(timestamp([Running Date]-1,'dd-MMM-yyyy'))"}>}
distinct [Run Id & Job Name Key]),[Running Date Start 1h], [Running Date],[Project Name]))