SSRS 2012 - Error: Subreport could not be shown

3.3k Views Asked by At

I'm using Visual Studio 2012 and my queries come from SQL Server 2012.

I currently have 5 reports that I am trying to bring into 1 main executive dashboard using subreports.

On my main executive dashboard, I add an initial subreport to the canvas in order to bring in one of the reports (Report1.rdl). When I right-click and go to Subreport Properties, under the general tab under "Use this report as subreport", I click and select Report1. I don't change anything underneath the Visibility or Border tabs. Under the Parameter tabs, I add these 4 parameters to run the sub report: StartDate, Rush, EndDate and Group using the format Name = StartDate, Value = @StartDate (and so on for the other 4 parameters.)

When I click OK, it says on the screen Report1 inside the Subreport grayed out box. When I try to preview the project, the 4 parameters show up at the top and are working, but the canvas shows "Error: Subreport could not be shown" where the subreport should be.

For the executive dashboard report, I recreated the same 4 parameters on it that are on all my other 5 reports (StartDate, Rush, EndDate, Group.)

Rush and Group are based off of two separate datasets using a simple query to populate.

SELECT  DISTINCT [RUSH]
FROM        TableA

SELECT  DISTINCT  [GROUP]
FROM        TableA
WHERE       [TEAM] = 'TeamA'

StartDate and EndDate are both Date/Time Data type parameters.

Under default values I specified the values for StartDate with the following expression: =DateAdd("d",-(Day(today)-1), Today) (to show 1st day of Current Month).

Under default values I specified the values for EndDate with the following expression: =DateSerial(Year(Now()), Month(Now()), "1").AddMonths(1).AddDays(-1) (to show last day of current month.)

The executive dashboard report also has its own Data Source MainDashboardDS which is based off DataSource1, a shared data source reference.

Anyways, I tried listing out everything I can think of above that may help with figuring out my problem...but my main question is, what am I doing wrong that I am getting this Error that my Subreport cannot be shown?

1

There are 1 best solutions below

1
smul86 On

It was in the values field...I needed the parameters to have the values with the brackets such as [@Group]...etc...