0

Some Salesforce objects have own section within Object Permissions list in specific profiles, other not. As I know ObjectPermissions has ParentId field which points to PermissionSet associated with profile. Setting Read Create Edit Delete View All or Modify All to true results creation of ObjectPermissions record. Otherwise setting all to false results deletion of ObjectPermissions record. In conclusion lack of Object Permissions record does not imply that object is not applicable to profile.

How Salesforce "knows" which objects / object permissions to show in setup for a given profile?

Is it possible to write SOQL query to retrive that data?

1 Answer 1

2

Based on this:

Profile and Permission Objects ERD

taken from the Profile and Permission Objects documentation and noticing that a PermissionSet can optionally be tied directly to a profile - presumably the permissions are defined for a profile via a hidden PermissionSet - I would guess that "yes" you can query the complete access permissions.

PS

On the subject of what is the most a Profile can access, that is controlled by the UserLicense and this query in the Developer Console returns some rows:

select Name, License.Name from PermissionSet order by License.Name

with what looks like built-in PermissionSet names. But there don't appear to be enough records for that to be the mechanism.

3
  • Helpful, but how to distinguish between all Object Permissions set to false and Object Permissions not applicable for profile? Example - Chatter Free User profile - without any ObjectPermissions and System Administrator profile with Object Permissions defined. Apr 11, 2021 at 14:36
  • 1
    @gpoluch I don't know if that information is visible; see my PS. Didn't read your question carefully enough...
    – Keith C
    Apr 11, 2021 at 15:04
  • Yep @Keith C. User License is the key. Salesforce documentation provides detailed information about Users Licenses and Objects associated with them? Apr 11, 2021 at 15:19

You must log in to answer this question.

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