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
Vincent FruchierVincent Fruchier 

Problem import data to account from the data loader.rh2.PS_Account: System.LimitException: Apex CPU time limit exceeded

Hello,

I have a problem when I import data to account from the data loader. Many records can not update because of a process failure: I have two different mistakes: rh2.PS_Account: System.LimitException: Apex CPU time limit exceeded Maximum number of duplicate updates in one batch (12 allowed). Attempt to update Id more than once in this Api call: It seems to me that the problem comes from an error in the processing capacity of SF, flow and APEX class?

Can you help me clean or disable these processes?

Thanks in advance.
Best Answer chosen by Vincent Fruchier
Khan AnasKhan Anas (Salesforce Developers) 
Hi Vincent,

Greetings to you!

This error usually arises from Apex triggers or processes running in the background which cause the maximum CPU time to exceed for a transaction. You can check the Debug logs/Event Monitoring.

The easiest way to overcome it would be to temporarily disable Apex triggers but it might produce some unwanted side-effects.

Another option (No need to deactivate the trigger) to try out is to set the "Batch Size" on the Apex Data Loader to a very small value say 10 or so.

Please refer to the below links which might help you further with the above requirement.

https://help.salesforce.com/articleView?id=configuring_the_data_loader.htm&type=5

https://help.salesforce.com/articleView?id=000232681&language=en_US&type=1

I hope it helps you.

Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.

Thanks and Regards,
Khan Anas

All Answers

Khan AnasKhan Anas (Salesforce Developers) 
Hi Vincent,

Greetings to you!

This error usually arises from Apex triggers or processes running in the background which cause the maximum CPU time to exceed for a transaction. You can check the Debug logs/Event Monitoring.

The easiest way to overcome it would be to temporarily disable Apex triggers but it might produce some unwanted side-effects.

Another option (No need to deactivate the trigger) to try out is to set the "Batch Size" on the Apex Data Loader to a very small value say 10 or so.

Please refer to the below links which might help you further with the above requirement.

https://help.salesforce.com/articleView?id=configuring_the_data_loader.htm&type=5

https://help.salesforce.com/articleView?id=000232681&language=en_US&type=1

I hope it helps you.

Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.

Thanks and Regards,
Khan Anas
This was selected as the best answer
Vincent FruchierVincent Fruchier

Hello Khan,

thank you for your return. I am not trained enough to disable APEX classes. I will try the method to set the batch size of the data loader.

Is going from 200 to 20 enough?

Thank you so much.

Have a good day

User-added image