What does the error mean? Oops...you don't have the necessary privileges to edit this record. See your administrator for help. mean?

449    Asked by ChrisDyer in Salesforce , Asked on Sep 4, 2023

 I am having an issue trying to implement a sample application from the book “Development with the Force.com Platform.” I am getting an error: Oops...you don't have the necessary privileges to edit this record. See your administrator for help.

The sample given is of the demonstration of manual sharing:

  1. In the example, two employees have separate roles: West and Central.

  2. The employee with the West role creates a manual share with Read Only permissions as   he owns a Resource record such that anyone with the Central role can go through the record.

  3. After that, the employee having the Central role has to make an Assignment record by using the shared Resource record and a Project record which he is having.

When I am trying to do this as the Central user I am getting the following message:


The following I have verified:

There is a rule for manual sharing for the mentioned resource, which is shared with the Central role.

I can read the record when I am logged in as the Central user.

When I am trying to set the Central user’s role to West(same as the Resource owner’s), then the Assignment can be created.

I have also checked that the user is indeed set as the Central role.

Are there any suggestions to know the security settings denying this operation exactly? Or is it some debugging?

https://salesforce.stackexchange.com/questions/1281/how-to-find-the-reason-for-insufficient-privileges

You might try to check the access of the Central user to whatever record type you are not able to create. Inspect at the profile and object level. You also need to check whether the record is set to private because when the resource (object privacy) is already ‘public read-only,’ and you try to create a share, the DML puts up an arbitrary exception.

It also depends on the kind of Profile and the employee you are using. There is a diagram on page 51; according to what we know, Assignment is an intersection object, and the child of both Project and Resource has a Master-Detail relationship and thus gets access from the Master. If you look at page 78, the Sales Rep and Consultant do not have to create access for the Assignments as they only have “Read” access to the Master records.

As mentioned above, your sharing rule might cause errors and is unnecessary, as everyone has read access to resources. An Assignment record can be created only by the Staffing Coordinator and Vice President as they are the profiles having appropriate access to it. Therefore, only these two profiles can create Assignment records, regardless of sharing.

Please go through the settings–

security (for profiles as well as roles)

sharing - yea, check again

views (if they use different ones) - to note, I don’t know which “book” you follow, so won’t be able to help on that.

Take a look at the above idea at ideasexchange and some of your problem might be solved.


Your Answer

Interviews

Parent Categories