I want to access the field value checked/unchecked for all profiles through SOQL.

enter image description here


To access permissions you need to use PermissionSet sobject and ProfileId field on it.

To read more about it, check documentation

Example of soql for your question:

select Profile.Name, PermissionsViewAllData FROM PermissionSet where IsOwnedByProfile = true
  • Thankyou @alexander, due to the field being categorized in administrative permissions, i got confused Jun 7 '17 at 9:30

You can use below query:

Select Name, PermissionsViewAllUsers, PermissionsViewAllData From Profile

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.