Friday, 11 November 2016

How to run the schedule a class in every five mins

Here is the cron expression to do so.


System.schedule('Schedule Job Name 2', '0 00 * * * ?', new Schedulerclassname());
System.schedule('Schedule Job Name 3', '0 10 * * * ?', new Schedulerclassname());
System.schedule('SSchedule Job Name 4', '0 15 * * * ?', new Schedulerclassname());
System.schedule('SSchedule Job Name 5', '0 20 * * * ?', new Schedulerclassname());
System.schedule('SSchedule Job Name 6', '0 25 * * * ?', new Schedulerclassname());
System.schedule('SSchedule Job Name 7', '0 30 * * * ?', new Schedulerclassname());
System.schedule('SSchedule Job Name 8', '0 35 * * * ?', new Schedulerclassname());
System.schedule('SSchedule Job Name 9', '0 40 * * * ?', new Schedulerclassname());
System.schedule('SSchedule Job Name 10', '0 50 * * * ?', new Schedulerclassname());
System.schedule('SSchedule Job Name 11', '0 55 * * * ?', new Schedulerclassname());

No comments: