
I seached over the internet and figured out that its because parallel running batch trying to update same parent object in different batches and solution provided was to group all activites related to same parent in same batch.
Unfortunately in our case an Account have more than 400,000 activites assciated with it and therefore I can't create a single batch of this size. Apart from this grouping activites for each Account and Contact is very painful as total count of Account + Contact is around 50,000. Wondering if there is a better solution to this problem.
Help is much appreciated!!!
Thanks.
답변 5개

There are couple of options that you can try:
1) Disable triggers or any settings that can lock parent while loading child data (this option might not be applicable to you).
2) Group your child data so its parent object does not fall in multiple batches.
3) Use bulk API in serial mode and set batch size to its max (i.e. 10000)
Based on my personal experience I found option 3 more viable when you have large data to load into the system.
Let me know if it solve your issue or you need any additional help.