0

Using SQL Server 2008, I have a SSRS report. Users can view this report on Sharepoint. I need to get user usage staticks for this report (like Number of Visits).

Which ways I can do it? Hope for you help.

Dmitry
  • 305
  • 5
  • 21

1 Answers1

3

This query:

SELECT c.Name,
       e.Timestart,
       e.TimeEnd,
       e.UserName,
       e.Status,
       c.Description,
       e.InstanceName,
       e.ReportID,
       e.TimeDataRetrieval,
       e.TimeProcessing,
       e.TimeRendering,
       e.Source
  FROM <yourSQLdatabase.dbo.ExecutionLog e
INNER JOIN <yourSQLdatabase>.dbo.Catalog c
    ON e.ReportID = c.ItemID
 where timestart >=  @startdate
   and timestart <=  @enddate;

is what I use to get report statistics. If you just need a count you can do a group by the c.name field with a count(*). The user calling the report is in e.userName; this includes scheduled reports which will come up with a name like "NETWORK SERVICE".

Mike Christie
  • 381
  • 1
  • 10
  • 2
    Oops; didn't notice that there was a link above pointing to a prior solution; that link gives additional useful information beyond what I've posted above. – Mike Christie Jul 22 '16 at 12:25