function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Sudheera LakmalSudheera Lakmal 

Schedule Apex Jobs in Production

Hello,
I have a batch Apex class that needs to be scheduled for every 15 minutes. I created below script and executed in Developer Console in sandbox environment. But I'm in doubt whether I can use the developer console in production to schedule this batch class as I don't have the Admin rights in Production Org. Can somebody has the experience Please confirm that whether we can use the Developer console in production to schedule the batch jobs? or If I cannot use developer console in production what are the other options available?

System.schedule('ScheduleInsertClaimInventoryManualAssign1','0 0 * * * ?' , new ScheduleInsertClaimInventoryManualAssign());
System.schedule('ScheduleInsertClaimInventoryManualAssign2','0 15 * * * ?' , new ScheduleInsertClaimInventoryManualAssign());
System.schedule('ScheduleInsertClaimInventoryManualAssign3','0 30 * * * ?' , new ScheduleInsertClaimInventoryManualAssign());
System.schedule('ScheduleInsertClaimInventoryManualAssign4','0 45 * * * ?' , new ScheduleInsertClaimInventoryManualAssign());

Thanks...!

Regards,
Sudheera Lakmal 
sandeep@Salesforcesandeep@Salesforce
Hi Sudheera, 

Click Apex Classes to go back to the Apex Classes page.
Click Schedule Apex.
For the job name, enter TestSchedulingApexFromTheUI.
Click the lookup button next to Apex class and enter * for the search term to get a list of all classes that can be scheduled. In the search results, click MySchedulableClass.
Select Weekly or Monthly for the frequency and set the frequency desired.
Select the start and end dates, and a preferred start time.
The schedule of a scheduled Apex job is relative to the user’s time zone.
Click Save.
To go to the Schedule Jobs page, from Setup, enter Scheduled Jobs in the Quick Find box, then select Scheduled Jobs.
You’ll see that your job is now listed in the job queue.
Click Manage next to the job’s name.
The page displays more details about the job, including its execution schedule.

But for this also you would need system Admin rights. 

Thanks, 
Sandeep Singhal
http://www.codespokes.com/
Sudheera LakmalSudheera Lakmal
Hi Sandeep,

Thank you very much for your reply.
Can we schedule the same batch job in every 15 minutes using this method? I tried to do that but couldn't. I noticed that we can schedule the job only once per hour using this method. But our business users want to run the job in every 15 minutes. 
I was able to do that by executing above script Anonymously in developer console of the sandbox, but I want to make sure that can I follow the same approach in production or not?

Thanks...!

Regards,
Sudheera