How to build SSRS reports (rptproj) with TeamCity and Visual Studio 2015

落花浮王杯 提交于 2019-12-02 00:21:55

问题


We have a build step to build a solution with about 70 projects using the Visual Studio (sln) as the runner type. We are able to successfully build other projects that are not supported by MSBuild, such as a vdproj file and office plug-ins by doing this. However, it apparently does not work for SSDT/SSRS projects. I have made sure the latest version of SSDT is installed to Visual Studio, and Visual Studio 2015 is directly on the build server.

rptproj is not supported by MSBuild and cannot be built

Is there any thing else I need to do to get these to build correctly? I have read about some people moving them to their own solution but that is not what we are after here, and I'm not sure that really is a fix to the problem.

This is important for us because we require the build output which targets SQL 2008 instead of copying the RDL's directly in the project which are the tooling version (SQL 2016).


回答1:


You have to build the rptproj by calling Visual Studio executable (devenv.exe):

"C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.exe" "[fullpath]\FooBarSolution.sln" /Rebuild [SolutionConfiguration] /Project KPI /Log "[fullpath]\Logs\KPI.Build.Log.log" /Out "[fullpath]\Logs\KPI.Build.Out.log"

Also you have to set the TargetServerVersion property of the project to SQL Server 2008



来源:https://stackoverflow.com/questions/39371766/how-to-build-ssrs-reports-rptproj-with-teamcity-and-visual-studio-2015

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!