1

As per the title I am wondering if it is possible to edit the default sharing settings for a particular Share object. For instance I would like to give a group of users edit access to the CaseShare object so that they can view the current sharing of a record and also create new share records if required.

I cannot seem to find a way to do this out of the box and wondered if anyone on here had a similar experience?

2 Answers 2

1

The rules for the Share object are complicated, and as far as I can tell, not well documented. Long story short, though, is that you won't be able to give specialized access to the share tables the way you'd like. You'll need to write some "without sharing" code to bypass the default security settings, either a Visualforce page or Lightning Component with some Apex code either way.

1

With what you are trying, it's not possible. Not all Objects have an associated Share object, so it's not possible to access a property which does not exist. E.g., an object on detail side of a master-detail relationship doesn't have one. You will need to address this on case by case basis.

Excerpt from Sharing a Record Using Apex:

Objects on the detail side of a master-detail relationship do not have an associated sharing object. The detail record’s access is determined by the master’s sharing object and the relationship’s sharing setting.

Additionally the same documentation mentions:

Sharing granted to users implicitly through organization-wide defaults, the role hierarchy, and permissions such as the “View All” and “Modify All” permissions for the given object, “View All Data,” and “Modify All Data” are not tracked with this object.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .