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

Apex Job Aborted By User

Hi, we've just tried to ask salesforce via a case why an Apex job is marked as aborted by User (when each User denies such knowledge) and they seem to think it's a developer request and pointed us here.

Case #11212305
Original request:
Hi, please can you let me know why the batch was "Aborted By User" as no one has aborted a job. Also can you state what the underlying error is - if there is one?
Apex Job Id: 7072000000vWcRV

Since this is an internal issue, I'm assuming the only folks who can help us the Salesforce employees who patrol these boards?

Thanks in advance.
SonamSonam (Salesforce Developers) 
Thanks for posting the details here, I will check your case and update you with my findings..
Hi Sonam,

Salesforce support have closed the case stating that these boards should be used.
The Batch job states the job was aborted by a User, who denies doing so (this has now happened twice) - this affecting the User concerned so I doubt they are ruining their own process!

Please can you advise what the reason for abort was?

Hi Sonam or anyone at Salesforce.... just raised another case to be pointed here again regarding aborted batches. New case #11330544. Same issue. Are you able to help?
Hi Cml,
I t happened in our org some time back and the batch was beeing failed and the reason was aborted by user. When i read the debug log, I saw an Internal Salesforce error. The support asked me to add filters in one of my queries which was taking very long time. Hope this helps
Juan SpagnoliJuan Spagnoli
You are experencing timeout problems, your query is running for more that 2 minutes so Oracle abort it. You need to optimize the query, to do that you need to focus on filters, check if you are using Indexed fields (Lookup Values, System fields, External Ids), if you are not, you can try creating one using "External ID" option or asking to support to create the index for your. The last thing that you can do, only if indexing doesn't help, is ask support to Create a Skinny Table for the object.

Here you have a lot of documentation about High Volumen Data, welcome to the world of timeouts ;)



IMPORTANT => Use this tool to check if your queries are "selective":

Good luck!