02 Mar 2025 01:47 PM
Hello,
Is it possible to filter on weekdays within anomaly detection?
Or is the a DQL weekday filter for timeseries?
KR Henk
Solved! Go to Solution.
13 Mar 2025 05:00 AM
@henk_stobbe There is a getDayOfWeek function available in DQL that can be used with timeseries , but could not really get that working in anomaly detector ....may be its not the right one to be used with AD
https://docs.dynatrace.com/docs/shortlink/time-functions#getDayOfWeek
Here is a query in a very crude form in case you want to try and experiment
timeseries {CPU_Util=avg(dt.host.cpu.usage),e=end()}, by: {dt.entity.host},interval:1h
| fieldsAdd CPU_Util_WD = if( getDayOfWeek(e[])>=1 and getDayOfWeek(e[])<=5, CPU_Util[] )
| fieldsRemove CPU_Util