0

Using SSRS 2014 enterprise.

I have a data driven subscription that should be generating about 500 reports as PDF files.

These reports are made up of a master report and two sub reports. If I view the report through the web portal, it works perfectly. The master report takes one parameter that is also passed to the sub reports, this parameter is data driven from a database query.

When I run the report through the subscription, all the expected PDF reports are generaeted on the file share, however they all only contain the below error, once for every sub report.

Error: Subreport could not be shown

The SSRS execution log doesnt contain anything helpful, only the below:

ERROR: Throwing Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: , Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Exception of type 'Microsoft.ReportingServices.ReportProcessing.ReportProcessingException' was thrown.;

Steven
  • 896
  • 2
  • 16
  • 29
Neil P
  • 2,920
  • 5
  • 33
  • 64
  • Maybe it's a security thing, is the job running with the correct privs? – Chuck Mar 23 '16 at 15:15
  • Other jobs are able to call the same stored procs without issue and a common data source is shared between them. – Neil P Mar 23 '16 at 15:20
  • Ok, maybe look at the event viewer on that server and see if you can get any useful error messages. – Chuck Mar 23 '16 at 15:24
  • Good shout, I hadn't thought about checking that! The only thing I can see are errors regarding a Terradata connector, which we are not using. Looking online this appears to be standard behaviour for SQL Server – Neil P Mar 23 '16 at 15:33
  • Thanks, I have a report, that is like yours, one master with two subs, runs fine, but when it is passed say 100 numbers, it grinds to a halt, and eventually times out. We run it only yearly, and I need to rewrite it to remove the sub reports. I think that is the only way to speed it up. – Chuck Mar 23 '16 at 15:36
  • The weird thing this, this produces 500 reports in about a minute. It's like it doesnt even attempt to run the stored procs to grab the data. – Neil P Mar 23 '16 at 15:52
  • In the report server configuration for that report, it must be looking at an execution snapshot, we have one report that takes to long to run, we have to re-generate the execution snapshot at 2:00 AM every night, that speeds up the report. If the report is using a execution snapshot, make sure that the job is creating it. Just some more ideas. – Chuck Mar 23 '16 at 16:04
  • It's set to "Always run this report with the most recent data" and not use any cache. and I haven't set any snapshot options, so presumably it shouldn't ever be used. I'm stumped! – Neil P Mar 23 '16 at 16:40
  • Hi Neil, I'm out of ideas also. Sorry about that. – Chuck Mar 23 '16 at 16:45

1 Answers1

0

This was caused by an error in the subreport. It appears that these errors are not passed up through to the logs, they are caught and then rethrown as an error that happened in the subreport, destroying any chance of identifying the error!

Running just the content of the subreport through a data driven subscription, I discovered the following:

When ran from a subscription, the job would hang, but log the following to the SSRS ReportServerService log (in the SSRS program files folder)

ERROR: Throwing Microsoft.ReportingServices.Diagnostics.Utilities.HasUserProfileDependenciesException: , Microsoft.ReportingServices.Diagnostics.Utilities.HasUserProfileDependenciesException: The '/REPORTNAME' report or shared dataset has user profile dependencies and cannot be run unattended.;

This error means that there was something in the report that had a dependency on the user.

The subreport was using the following parameter to log to a trace table:

[&UserID]

Replacing this with a value that is not user dependant value allowed the subscription to run.

Neil P
  • 2,920
  • 5
  • 33
  • 64