Issue
I'm using node-cron to run scheduled jobs. I want the jobs to run every 45 minutes, but its acting strangely
Here's the pattern I'm using
I started my script at
Tue Jun 17 2014 08:17:39 GMT+0000 (GMT)
Here's are the first couple of times the job was executed
1. Tue Jun 17 2014 08:45:03 GMT+0000 (GMT)
2. Tue Jun 17 2014 09:00:01 GMT+0000 (GMT)
3. Tue Jun 17 2014 09:45:02 GMT+0000 (GMT)
This is definitely not what I expected or want. All I want is to run the Jobs every 45 minutes. Can anyone help me with the pattern? Thanks :)
Solution
You're probably looking for
0 */45 * * * *
The ranges are here.
- Seconds: 0-59
- Minutes: 0-59
- Hours: 0-23
- Day of Month: 1-31
- Months: 0-11
- Day of Week: 0-6
Answered By - Ben Fortune Answer Checked By - Dawn Plyler (WPSolving Volunteer)