function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Urich NOUPIKUrich NOUPIK 

Apex or SOQL development

Hi,
Please i need to have Profile Name with Object Access Permission by using Apex or SOQL. I use this query but the Profile name not appears corretly as you can see in the attached picture. Please someone can help me? I need it to extract metadate for a project.

SELECT Id, Parent.Name, Parent.Profile.Name, SobjectType, PermissionsCreate, PermissionsRead, PermissionsEdit, PermissionsDelete, PermissionsModifyAllRecords, PermissionsViewAllRecords FROM ObjectPermissions ORDER BY Parent.Name, SObjectType

User-added image
 
Alain CabonAlain Cabon
Hi,

You should use the workbench: https://workbench.developerforce.com/

The header values are converted but the values of Parent.Name, Parent.Profile.Name are correct
Raj VakatiRaj Vakati
You can not see them in the developer console ..  

Go to the workbench and export the data using this SOQL  ..  Use any other data export tools 


SELECT Id, Parent.Name, Parent.Profile.Name, SobjectType, PermissionsCreate, PermissionsRead, PermissionsEdit, PermissionsDelete, PermissionsModifyAllRecords, PermissionsViewAllRecords FROM ObjectPermissions ORDER BY Parent.Name, SObjectType
Urich NOUPIKUrich NOUPIK
Use workbench can not help me because i want to create an app that allows customer to generate his metadata and the profile name is obligated with associated permissions