+ Start a Discussion

Getting user permissions level to records via API

Hello All,

I'm facing with the same problem now as it posted 2 years ago in the following link :


Does anyone know whether SF found solution for this problem?


Basically we have two options, but both of them are not elegant and very complicated:

- The first option is the "Try and See" option, i.e. update all the records we retrieve and separate between them according to the error response we got --> it damage our reports because it will change the LastModifyBy/Date fields.


- The second option is to simulate SF security mechanism per each record, which is very complicated since we need to count on the object_Share__c data which includes groups & users (recursively) and their are a lot of exceptions such as "Modify All" permission and o lot more..


It's really weird that SF not provides solution to support this problem, the desired solution will be to retrieve records with direct information about the user permission according to a specific record (which user? the one that made the API call of course).


Any piece of information will help,

Thanks in advance,



Nope, still no means of figuring out row-by-row security other than the 2 methods you laid out.


Option 3: Start with a SavePoint (Database.setSavePoint), perform your DML operations, check for success/failure, then roll back your changes. You get the benefits of using salesforce.com-defined security without damaging your reports.