Questions tagged [locking]

The tag has no usage guidance.

22 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
6
votes
1answer
50 views

Apex Approval.lock, programmatic locking and record editability

Background: In Winter '16, Salesforce introduced the Approval class for setting approval locks and unlocks through Apex (release notes). Since then, my company has been leveraging this functionality ...
4
votes
1answer
339 views

SObject type does not allow locking rows

I am trying to update a group of records satisfying certain conditions it was giving me Error which says:- UNABLE_TO_LOCK_ROW, unable to obtain exclusive access to this record or 10 records so ...
2
votes
0answers
57 views

Resolving UNABLE_TO_LOCK_ROW issue

Is there any way to identify which transaction/class took the lock the record when we get this UNABLE_TO_LOCK_ROW issue. Simply giving UNABLE_TO_LOCK error and not giving the idea about he potential ...
2
votes
0answers
146 views

Group membership locks - Territory Hierarchy updates & Sharing recalculations

I read through the Record Locking Cheat Sheet to understand record locking concepts and have some follow-up questions: What can be the cause of Group membership locks with relevance to Territory ...
2
votes
0answers
267 views

Checking Object Lock status using REST API

We are running into the object lock contention UNABLE_TO_LOCK_ROW error when attempting to create a record in the CampaignMember object using AMPscript in Marketing Cloud due to the high lock ...
2
votes
0answers
791 views

CreateSalesforceObject AMPscript function and Record Locking Concurrency

We are using the CreateSalesforceObject AMPscript function to create a new record in the Salesforce CampaignMember Object when an email is sent, by including the following code in an email: set @...
2
votes
0answers
99 views

Unlock parent, then update child, then again lock back the parent

I have a batch class that is used to update a Field1 of Obj1. Obj1 is child of Obj11. Inorder to update Obj1, I need to unlock its parent Obj11 first. [by updating lock__c=false]. Then update ...
2
votes
0answers
121 views

Salesforce Optimistic Record Locking and JavaScript Updates

Is there a way to implement field only updates for Salesforce? Even if fields could be updated concurrently through JavaScript/JavaScript remoting calls, would Salesforce still save the record using ...
1
vote
0answers
31 views

Locking Attachment During Approval Process is failing

I am trying to lock the Attachments related to a custom object using the below 2 lines of code, when the custom record is under approval process. But I am getting an error as: "System....
1
vote
0answers
28 views

Record Lock Issue for REST endpoint

I have built a REST endpoint, which writes data(Accounts) to Salesforce. Currently, for a single record, there could be multiple (20-30 times) upserts within 1-to-5 seconds. Behind the scenes, it's a ...
1
vote
0answers
76 views

Challenge unlocking a list of objects in my logic

I am trying to using Approval class to lock and unlock records of an object xyz__c. When I run the below code I still see the record as locked and unable to perform update on it: List<xyz__c> ...
1
vote
0answers
78 views

Questions on row locking/transaction control

I have a process that first reads a custom setting value to use in a numbering scheme (can't use auto-number), it +1 that value, updates it, then does a number of DML/logic code which can take a ~2-10 ...
1
vote
0answers
104 views

Can a validation rule cause a record to be locked?

I've been having trouble with a large system which uses lots of batch processes where I keep getting errors with UNABLE_TO_LOCK_ROW exceptions. I read the locking Cheat Sheet here: http://resources....
1
vote
0answers
246 views

Tips to prevent errors in execution of time-based workflow?

Our implementation includes a number of time-based workflow rules. Due to high volume, we have been experiencing frequent occasions where execution of updates to some records in the time-based ...
1
vote
1answer
90 views

Unable to lock record from Apex web service method

I have a class that's used to prioritize leads in a lead queue based on rules that our business users can create and manage. One method in particular is used to find the first record in the ...
1
vote
1answer
435 views

Causes of organization lock

I recently tried to deploy some changes between sandboxes using the Force.com migration tool and got the following error: Failed to process the request successfully. Cause(ALREADY_IN_PROCESS): null:...
0
votes
0answers
20 views

How to avoid locking a record when the approval process is pending?

I need to have records of a given objects unlocked during the pending phase of the approval process. I tried to use a trigger on the object under the after update condition and check the status of ...
0
votes
0answers
25 views

CTI and Record Lock

I have an issue where records are being locked while my reps are using them. The basic steps are like this: Navigate to Opportunity Contact information is pulled via an Action Layout Editor Rep ...
0
votes
0answers
243 views

Unable to lock row - Record currently unavailable error

I know there has been lot of things available online for record locking errors but I am putting my analysis based on client issue that we are facing, would appreciate if I can get any thoughts. We ...
0
votes
1answer
71 views

Relock record after approval process

Is there a way to re-lock a record immediately after it has been approved via an Approval Process (in the same transaction)? It seems like a simple thing to do via a Trigger but I have an After ...
0
votes
1answer
137 views

Organization Administration Locked

good old message is the following : Organization Administration Locked The changes you requested require salesforce.com to temporarily lock your organization's administration setup. However, ...
0
votes
0answers
560 views

UNABLE_TO_LOCK_ROW - Insert

I am inserting records into a custom object via interface. I deactivated the triggers on this object so there is no additional code getting triggered upon insert. Still i am receiving the error: ...