You need to sign in to do that
Don't have an account?
Bhagyashree Suryavanshi
How to schedule more than 100 jobs?
You have exceeded the maximum number (100) of Apex scheduled jobs.
Hi, Is there any workaround to overcome the above governor limit?
Hi, Is there any workaround to overcome the above governor limit?
You can create schedulable class (not a batch, not a future) and that class would invoke two batch jobs one after the other one. This would mean you are scheduling only one class, but you are able to run two batch jobs at the same time.
Note:- The batch jobs would run one after another. The second batch job would start, once the first one is finished.
A sample Apex snippet is below:-
//declaration of scheduler class
global class ScheduleMultipleBatchJobs implements schedulable
{
//method to implement Apex schedulers
global void execute(SchedulableContext ct)
{
BatchDeletion BD = new BatchDeletion();
Database.executebatch(BD);
UpdateAccountFields UP = new UpdateAccountFields();
Database.executebatch(UP);
}
}In the above example we are invoking two batch jobs (BatchDeletion & UpdateAccountFields) with one schedulable class (ScheduleMultipleBatchJobs).
Thank You,
www.nubeselite.com
Development | Training | Consulting
Please mark this as solution if your problem is solved.