Filter Date Range

Hello Community,

I am trying to create a data range for my analysis.

I have the below equation which works:
FILTER “CASES”.“NetDueDate” BETWEEN ADD_DAYS(TODAY(),-6) AND TODAY() ;

However, i would like to replace the 2nd ‘TODAY’ with ‘the last day of the prior month’ - 6.

Can you please let me know if this can be achieved in Celonis?

Many thanks,
Anna

Hello Anna,

Thanks for reaching out! Since the last day of a month varies, the easiest way is to get the first day of the current month and subtract one day. This can be achieved with ROUND_MONTH() which sets all other date values (e.g. days, minutes…) to their ground state.

More specifically, the following function returns the last day of the previous month:

ADD_DAYS(ROUND_MONTH(TODAY()),-1)

I hope this formula and the explanation help solving your problem.

Best,
Viana

1 Like