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
Simon_FranceSimon_France 

Retrieve logged as soql history

Hi everyone,

I work for an ISV and sometimes the customer make some data modification as I'm working on his org.

All modification are written as done by the user I'm logged with so it's impossible afterwards to know if I did the modification or him.

Is there any way through SOQL to retrieve who really did the modificaition ?

I use this kind of SOQL from this article (https://developer.salesforce.com/docs/atlas.en-us.soql_sosl.meta/soql_sosl/sforce_api_calls_soql_relationships_query_hist.htm) :
SELECT OldValue, NewValue, Parent.Id, Parent.name, Parent.customfield__c 
FROM foo__history

I'm looking for, if it's possible, the right field to put in select to retrive this information.
Best Answer chosen by Simon_France
SwethaSwetha (Salesforce Developers) 
HI Simon,

Using Setup audit trail we can check any changes made to the set up, password reset and also find who has logged as which user, Using the debug logs we can see, what modifications are made on a record, However we cannot differentiate who has made the change ( Logged in user or the user himself) . I believe there is no other way to identify changes made.

 
Hope this helps you. Please mark this answer as best so that others facing the
same issue will find this information useful.
 
Thank you

All Answers

SwethaSwetha (Salesforce Developers) 
HI Simon,

Using Setup audit trail we can check any changes made to the set up, password reset and also find who has logged as which user, Using the debug logs we can see, what modifications are made on a record, However we cannot differentiate who has made the change ( Logged in user or the user himself) . I believe there is no other way to identify changes made.

 
Hope this helps you. Please mark this answer as best so that others facing the
same issue will find this information useful.
 
Thank you
This was selected as the best answer
Simon_FranceSimon_France
Hi Swetha,

"However we cannot differentiate who has made the change"

I was afraid of this... I will maybe ask for a new feature.

Thanks for your quick answer !