sql-server-data-tools

SSDT/SqlPackage drops statistics

此生再无相见时 提交于 2019-12-13 07:48:17
问题 During build we generate dacpac files of our database based on a SSDT .sqlproject. This dacpac later gets deployed to production using sqlpackage. Despite using the /p:DropStatisticsNotInSource=False switch, sqlpackage will drop all statistics, that were added after the last sync of the sqlproject with the production database. We can also reproduce this using a publish profile and the generate script option of SSDT: <?xml version="1.0" encoding="utf-8"?> <Project ToolsVersion="14.0" xmlns=

How to build and deploy SSRS project through VSTS?

蹲街弑〆低调 提交于 2019-12-13 02:29:29
问题 I created simple SSRS project in VS2015. I want to build and deploy the SSRS project using VSTS by creating the build definition and release definition steps. Is there any third party VSTS extension available or for SSRS build and SSRS Deploy not same like as SSIS Build and SSIS Deploy tasks? Can you please tell me how to build and deploy SSRS project through VSTS? 回答1: There is SQL Server Reporting Services Deployment extension. Simple sample tasks: Command Line (Tool: C:\Program Files (x86)

Export sql server registration info from VIsual Studio

蓝咒 提交于 2019-12-13 02:16:08
问题 how can i export all my sql server registered in SQL Server Object Explorer? I try Import and export settings but it dont save them 回答1: To my knowledge there's not a built-in mechanism that will save and restore these settings. The connection string data is saved in the registry under HKEY_CURRENT_USER\SOFTWARE\Microsoft\SSDT\ConnectionStrings so you could perhaps export the settings from there. The standard disclaimers about editing the registry being dangerous apply, as always. 来源: https:/

Using MSBuild to build SSDT projects with VS2017 fails

混江龙づ霸主 提交于 2019-12-12 22:42:15
问题 I am trying to set up continuous integration of .sqlproj SSDT projects on our windows server 2016 server. In order to do this I have installed VS2017 and SSDT tools onto the server to get the required tools. I have also installed MS build tools 2017. The issue I am currently having is regarding what looks to be miss-matched versions of installed ms build tools and ssdt. The command i am using to run the build is as follows: C:\\Windows\Microsoft.NET\\Framework64\\v4.0.30319\\MSBuild.exe /p

MSBuild & SQL Server Database Project: bind the deploy and publish desination to the build configuration

…衆ロ難τιáo~ 提交于 2019-12-12 22:13:32
问题 Visual Studio 2012. SQL Server Database Project. Four build configurations were created in solution: Debug, DevDb, TestDb, LocalDb. Three publish profiles were created in project: DevDb.publish.xml, TestDb.publish.xml, LocalDb.publish.xml Pushing F5 button (!) I want to: deploy project with connection string from project properties if build configuration is Debug . publish project with connection string from the corresponding publish profiles if build configuration is DevDb , TestDb or

Why does a tSQLt test pass in Visual Studio Test Explorer when it should fail?

早过忘川 提交于 2019-12-12 15:41:28
问题 I'm writing some tSQLt tests and running them using Visual Studio's Test Explorer via the tSQLt test adapter extension. I'm doing TDD, so I'm writing the test before writing the stored procedure that it tests. The problem is, when I run the test, it should fail because the stored procedure does not exist yet. When I run the test with tSQLt in Sql Server Management Studio it fails like it should: The module 'test_ValidCustomerName_CustomerIdIs1' depends on the missing object 'dbo.AddCustomer'.

Invalid file names when trying to deploy SSDT project with TeamCity 8

旧巷老猫 提交于 2019-12-12 13:18:10
问题 I am trying to deploy Visual Studio 2012 SSDT project to Sql Server using TeamCity 8 and MSBuild Publish task but the deployment fails. When I look at TeamCity logs and use /v:diag switch in my build configuration I see that for unknown reason MSBuild searches for MyProject .sqlproj .publish.sql and for MyProject .sqlproj .dacpac files. The exact error: [SqlPublishTask] C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\SSDT\Microsoft.Data.Tools.Schema.SqlTasks.targets(1233, 5): File

Where the data-tier application version number is stored in a Visual Studio project?

↘锁芯ラ 提交于 2019-12-12 11:22:42
问题 I have an utility which fills version numbers in AssemblyInfo.cs files. Now I need to implement a functionality to adjust version numbers for Visual Studio Data-Tier applications (DACPAC). I see that I can adjust the number manually if I open project properties and click the Data-Tier application Properties button. But I cannot find where this number is stored in project files, so I have no idea how to update it automatically from my utility. Do you know, where is the version number stored?

Do I need a database reference for a linked server in a SQL Server database project?

柔情痞子 提交于 2019-12-12 09:35:40
问题 In my database project, I have added a reference to a linked server. When I use this linked server in a view and try to build my database project, SSDT reports errors because it cannot understand references to any of the schemas referenced on the linked server: [LinkedServer].[DB1].[dbo].[Table1] The above would returns an error that SSDT cannot decipher the reference to [DB1].[dbo].[Table1] . I tried to add a reference to this database, but SSDT required either a .dacpac file (produced by

DACPAC not including composite objects

*爱你&永不变心* 提交于 2019-12-12 08:59:54
问题 I have a VS2012 database project which includes tables, stored procs, views etc. I then have a second database project which contains a database reference to the first project. I have ensured that the "Include composite objects" options is selected from the "Project Properties -> Debug -> Advanced" menu. When I build the second project and take the resulting DACPAC file and deploy it through SSMS2012 it doesn't create the firsts project's objects. Am I missing something? Why don't the