MS CRON expression for Azure Function

118 Views Asked by At

I need a CRON expression, compatible with Azure Functions V2, to express such intervals:

  • every 30 minutes from 8:30 to 18:30 (including 8:30 and 18:30)
  • every 5 minutes from 7:00 to 7:45 (including 7:00 and 7:45)

Is there a way to do such a thing?

1

There are 1 best solutions below

1
Pravallika KV On

You can use the below CRON expressions to achieve your requirement:

  1. every 30 minutes from 8:30 to 18:30 (including 8:30 and 18:30)

30/30 8-18 * * *

This CRON expression helps to trigger the function at every 30th minute from 30 mins past the hour between 8 and 18(i.e., 8:30 to 18:30).

enter image description here

  1. Every 5 minutes from 7:00 to 7:45 (including 7:00 and 7:45):

*/5 7 * * *

This expression helps to trigger the function at every 5th minute between 7 and 7:59(that includes 7:45).

enter image description here

You can verify these expressions at Online CRON Expression Generator.