Activity Forums Salesforce® Discussions In case of parallel data loading, how to avoid record locked error in Salesforce?

  • shariq

    Member
    September 22, 2018 at 6:16 pm

    Record locked error can be avoided by two ways

    Change schema of Object : Check every Lookup field and make sure that in Lookup Option you have notselected “Don’t allow deletion of the lookup record that’s part of lookup relationship”. Because of this selection, even during insert operation system hold lock against record and other batches accessing same record fails.
    Order Insert operations in CSV File : In this option, Sort column containing parent record Id for Lookup fields. So all records of same parent will be loaded in same batch and parent record locked problem across batch will be resolved

  • Parul

    Member
    September 23, 2018 at 6:18 am

    Check your code mainly triggers written on code or code entry may have FOR UPDATE clause included in them. Remove them and it will work fine.

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos