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
KunlunKunlun 

Can Analytic Snapshots be used in apex?

Hi All

 

I checked all the document in apex code, but could not find any sample to use Analytic Snapshots.

There is only some description, which said "Analytic Snapshots can be used in api".

 

Any one can help me?

 

Kunlun

jucuzoglujucuzoglu

There should be an object you can access via SOQL called Snapshot_Data__c. You can run quieries against that object to capture data. You should also be able to use standard DML operations to Insert/Upsert/Update/Delete etc... data records.

KunlunKunlun

Hi jucuzoglu

 

I searched all the document and forum, but didn't find class "Snapshot_Data__c", only find object "AnalyticSnapshot". Do you think they are same?

Can you provide some sample code how to use it? (I didn't find any sample code either.:smileysad:)

 

Thanks very much.

 

Kunlun

jucuzoglujucuzoglu

Are you using the Force.com IDE for development. You should explore the Schema and see if your finding it in there. Also which version of Salesforce (i.e. Enterprise) are you running?

KunlunKunlun

I'm using development version. And do programming code with document on SFDC web page directly.