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
n_pavan_kumar1n_pavan_kumar1 

what is the real time use of Analytic snapshot?

hi,

 

I want to know the real time uses of analytic snapshot.

I have created an analytic snapshot and it  runs according to the schedule. Basically it adds the records from the source report into target object. What is the use of it?

 

Can any one give some application of analytic snapshot?

rjheiserjheise

I know one use is to take data from a report of a changing state and store the results for use in a trend analysis.  An example would be a report on number of open cases by rep.  This would change every day, but there is no way to store those results for past days.  You can store that snapshot and would be able to report on the trend over time.

 

Any report of a count of something an account or user is related to would be a candidate for this trend.  Like number of open opportunities or activities by account or user.

 

I am trying to use it for something completely different.  I want to summarize sales data by customer and then show that as part of a related list on the account record.

 

I run a report that groups invoice item detail by customer and then by item.  I created calculated fields on the invoice detail record that stores the qty and sales amount separately for this year and last year invoice dates so I can use those as summary fields on the report.  I use the Account ID in the report and created a field on the snapshot object with a lookup to the account, so it will link the snapshot record to the account.

 

The snapshot loads perfectly showing:

 

Account    Item   PYR Qty   PYR Sales   YTD Qty   YTD Sales

 

with each item a separate line for each account in the snapshot object.

 

When I show the related list on the account, you can see a summary by item of what that account purchased this year and last year.

 

The problem I am having is that the snapshot inserts all new records each time it runs.  I created a key field made of the account number and item number on the report and loaded it in the snapshot object and was hoping the process would just update the records in the snapshot object rather than create all new records.  If I can't get it to update, I need to figure out how to automatically clear out the snapshot object each evening before the report runs.