cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Filter data by previous calendar month automatically.

Maelam
Observer

Hi there.
Is it possible to filter data by calendar month in DQL Notebooks? I cannot seem to find a query that I can use to filter data by previous month using calendar month. I want a dashboard that would automatically show data for the past month but from the 1st to the last day of the month. An example could be fetching the number of Davis Problems for the past month.

fetch events
| filter event.kind == "DAVIS_PROBLEM"
| summarize Total_Problems = count()

 

I want this to show for the previous month, each month.

3 REPLIES 3

Mizső
DynaMight Guru
DynaMight Guru

Hi @Maelam 

Please check this post, maybe it could help.

TIPS - DQL Timeframe selection - Dynatrace Community

I am not a DQL user unfrotunately (yet).

But maybe you can create an -1M/M based on @gbaudart post.

I hope it helps.

Best regards,

Mizső

Dynatrace Community RockStar 2024, Certified Dynatrace Professional

Thanks, Mizső but I do not think that this will be useful. I want the data to always show the previous calendar month regardless of whichever day I want to run the query/report.

Mizső
DynaMight Guru
DynaMight Guru

Hi @Maelam

I allocated some time to check it but you are right I have not found any solution yet in DQL based on the documentation and examples. So at the moment you can do this only on the Dashboard Classic (+Data Explorer) with timeframe selection -1M/M to now/M.

Best regards,

Mizső

Dynatrace Community RockStar 2024, Certified Dynatrace Professional

Featured Posts