4
votes

I have an SSRS report project I'm working on in Visual Studio 2015, and I am unable to deploy my reports to the correct target server version.

The reports need to be able to deploy and run on SQL Server 2012, 2014 and 2016. Visual Studio 2015 allows for a Target Server Version option for the project of 2008R2, 2012, or 2014, which is what the target server version of the project is set to. The designer automatically upgraded the source RDL file schema to the 2016 version of the report once you open and do anything within it. I understand this part is by design.

The problem comes when you build the report. The build output files in the \bin\Debug or \bin\Release folders are not targeted to the correct server version. The following tag looks like it updates correctly in the output files:

<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">

However, the build fails to remove and leaves behind all of the other SSRS 2016 tags within the built RDL files, and as such cannot be deployed to SSRS 2012 or 2014.

I have Visual Studio 2015 v 14.0.25431.01 installed with SQL Server Data Tools v14.0.60812.0 with SQL Server Reporting Services 13.0.1700.68.

Is there something that I'm missing that needs to be done as well besides setting Target Server Version to "2008R2, 2012, or 2014" to get it to build to the correct Target Server Version?

1
Well, I should probably at least put something in here for others looking. Anytime we try to upgrade the files to use the VS2015 designer with the target server version set to 2008R2, 2012, or 2014, (after MS updates, etc.), they fail to run at all on any of those target server versions. We ended up just reverting all the RDLs back to their original formatting, and we have just been editing the code directly. Doing that, it still builds alright in VS2015 and we can at least deploy them, just means that we can't use the designer at all.mcol2007
The 2016 specific xml tags in the RDL file in the bin directory are simply ignored when deploying to the server, getting the namespace right is the key...Trubs

1 Answers

1
votes

I had this same problem. What I needed to do to resolve this was

  • Clean the project
  • Under Project > Properties > General set TargetServerVersion to "SQL Server 2008"

  • Set TargetServerVersion to "SQL Server 2008 R2, 2012 or 2014"

  • Rebuild the project

Your project should now deploy to the correct version