Print this page

How many types of Apex jobs have run in my instance per day?

Knowledge Article Number 000182128
Description Sometimes it's necessary to determine how many types of jobs have run per day, such as Future, SharingRecalculation, ScheduledApex, BatchApex, etc. This information can be discovered with a simple query of the AsyncApexJob table. 
For example, here is a query that shows the number of Future jobs that have ran per day within an org:
SELECT COUNT(Id), day_only(CreatedDate) FROM AsyncApexJob where jobtype = 'Future' group by day_only(CreatedDate) 
To change the type of AsyncApexJob type (among Future, SharingRecalculation, ScheduledApex, BatchApex, BatchApexWorker, TestRequest, and TestWorker), you need only to change the value of the "where" clause. 

promote demote