Reputation: 58063
I am using Java - Spring - Quartz Scheduler. I want to run job by 3 AM in the morning and following is my cron expression.
0 0 3 * * ?
Can somebody tell me is it the correct one? Will it execute twice in 24 hour 3 PM and 3 AM?
Upvotes: 6
Views: 18467
Reputation: 7101
I have checked your expression in the CronMaker.
This only works for 3:00 AM every day. If you need for 3 AM and 3 PM, use this:
0 0 3/12 1/1 * ? *
Upvotes: 4
Reputation: 240870
Yes this is correct, you can verify it by this, and it takes 0-23 for Hhour field so it will invoke at 3 am
Upvotes: 6