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
Madhu D 24Madhu D 24 

How do we display Standard big Object Data by using LWC component and SOQL query?

Hi Everyone, Please let me know how we can display data from FieldHistoryArchive in LWC?
 As of now i am getting the error as sObjecttype 'FieldHistoryArchive' not supported
Note: if we Give view all permission then he is able to View FieldHistoryArchive data. But i don't want to give view All permission to Lower Profiles
 
Please suggest me the Best approach.
we can display it By using Reports and Dashboards, But want to know if there is anyway from LWC

Best Answer chosen by Madhu D 24
Madhu D 24Madhu D 24
Hi everyone for this we need to run our APex in system contect without sharing

All Answers

VinayVinay (Salesforce Developers) 
Hi Madhu,

You would need to have View All Data permissions to query and display 'FieldHistoryArchive'.  If you do not have you would see above error.

Similar reference.
https://salesforce.stackexchange.com/questions/179656/sobject-type-fieldhistoryarchive-is-not-supported

Please mark as Best Answer if above information was helpful.

Thanks,
Madhu D 24Madhu D 24
Hi everyone for this we need to run our APex in system contect without sharing
This was selected as the best answer