0

A year back I scheduled "Scheduled Apex" job via System.Schedule method (anon apex).

The job has been running once a day during this time.

Today I would like to check the end date (if any) of this scheduled job.

I could not find this information (end date of this job) from Salesforce UI.

Is there any way by which I can get this information ?

Basically we would need this job to run nonstop (once a day).

1
  • If you scheduled it via Apex, it doesn't have an end date unless you put one in your cron expression.
    – Adrian Larson
    Commented Dec 18, 2017 at 23:55

1 Answer 1

2

You want the EndTime field on the CronTrigger object. You could see the end date for all scheduled jobs with this query:

SELECT EndTime, CronJobDetailId, CronJobDetail.Name
FROM CronTrigger WHERE CronJobDetail.JobType = '7'

You could of course hard code or otherwise filter on CronJobDetailId to meet your specific needs.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .