I'm trying to find a way to query information in Apex regarding AnalyticSnapshots ("Reporting Snapshots" in the UI). The object itself isn't queryable via SOQL, but I thought I might have found a workaround with the following:


...where is the id of a Report that is the source for a reporting snapshot. I have verified the snapshots are running for this report; I see the history in Setup UI.

The documentation on this method are quite light on details. Wondering if anyone here can shed light on whether the meaning of "historical snapshots" is referencing Reporting Snapshots, or something else.


What you are referencing are Historical Dates that you can setup (up to 5 dates) to compare values with Historical Trend reports.

What you are looking for is AnalyticSnapshot, but I'm not aware how ot retrieve a history of all runs.

All I know that Reporting Snapshot Name, Reporting Snapshot Running User, Execution Time can be added to each Snapshot record (on a Custom Object) that can be used to run SOQL to get some statistics.

| improve this answer | |

There is the dedicated Analytics REST API that mentions report snapshots in relation to the /wave/trendedreports resource.

It isn't entirely clear if trendedreports are Reporting Snapshots or something else entirely. Reporting Snapshots have the keyprefix 0A0 (ReportJob).

I tried quickly in my dev org. While I could create the a Reporting Snapshot the REST API returned the error:


[ {
  "message" : "This feature is not currently enabled for this user type or org: [Wave]",
} ]
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.