data-tier-applications

DacServices.GenerateDriftReport throws sql server version Conflict

笑着哭i 提交于 2020-01-02 20:23:36
问题 I have a microsoft sql server 2014 instance with a database "myDB". In SSMS I have registered this database as Datatier application. I have installed the latest dacfx with nuget to my visual studio project. When I hit DacServices.GenerateDriftReport("myDB") it throws: Databases registered as a DAC database must be hosted by an instance of SQL 2005 SP4, SQL 2008 SP2, SQL 2008 R2, SQL 2012 or SQL Azure. Also the method DacServices.Unregister throws this error. I am installing Windows Server

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?

How to deal with temp tables when compiling database project

試著忘記壹切 提交于 2019-12-07 21:46:58
问题 We just created a solution with multiple data projects. We inherited the system and want to do a database cleanup but when we compile some of the databases we get the error that table, id etc does not exist and it occures where temp tables are created in stored procedures. Let's say a stored proc creates a temp table and at the end drops it the compiler complains and says that the table does not exist (in the database schema). How can we work around this? Any settings I can't find? Thanks in

How to extract MSSQLServer database as .dacpac without VerifyExtraction?

我是研究僧i 提交于 2019-12-03 08:33:16
问题 I want to extract a database schema of a MSSQLServer database with Server Management Studio. I use the Extract command "Extract Data-tier Application.." In the database are several references to another database. Because of this I get the following error. Error extracting database: Validation of the schema model for data package failed. Error SQL71562: Error validating element [dbo].[x] has an unresolved reference to object [dbo].[y]. External references are not supported when creating a

How to extract MSSQLServer database as .dacpac without VerifyExtraction?

淺唱寂寞╮ 提交于 2019-12-02 22:19:15
I want to extract a database schema of a MSSQLServer database with Server Management Studio. I use the Extract command "Extract Data-tier Application.." In the database are several references to another database. Because of this I get the following error. Error extracting database: Validation of the schema model for data package failed. Error SQL71562: Error validating element [dbo].[x] has an unresolved reference to object [dbo].[y]. External references are not supported when creating a package from this platform. The problem is, that SSMS uses the SQLPackage.exe with parameter /p

How do I find the current version of a SQL Server data-tier application?

拈花ヽ惹草 提交于 2019-11-30 12:45:36
We are using a SQL Server Data-tier application (dacpac or DAC pack) and I'm having a hard time finding the current version of the database. Is there a way to obtain the current version using any of these methods: From within SQL Server Management Studio Via a SQL statement Programmatically using .NET code From within SQL Server Management Studio From http://msdn.microsoft.com/en-us/library/ee210574.aspx To view the details of a DAC deployed to an instance of the Database Engine: Select the View/Object Explorer menu. Connect to the instance of the from the Object Explorer pane. Select the View

How do I find the current version of a SQL Server data-tier application?

大兔子大兔子 提交于 2019-11-29 17:59:13
问题 We are using a SQL Server Data-tier application (dacpac or DAC pack) and I'm having a hard time finding the current version of the database. Is there a way to obtain the current version using any of these methods: From within SQL Server Management Studio Via a SQL statement Programmatically using .NET code 回答1: From within SQL Server Management Studio From http://msdn.microsoft.com/en-us/library/ee210574.aspx To view the details of a DAC deployed to an instance of the Database Engine: Select

ServerConnection.ExecuteNonQuery in SQLCMD Mode

我是研究僧i 提交于 2019-11-29 07:55:36
问题 I am using the Microsoft Data-Tier Application framework to create a deployment script based on a DacPackage object. I am attempting to use the Microsoft.SqlServer.Management.Smo.Server class to execute this script... SqlConnection deployConnection = new SqlConnection(connBuilder.ToString()); deployConnection.Open(); Server server = new Server(new ServerConnection(deployConnection)); server.ConnectionContext.ExecuteNonQuery(deployScript); However, this errors out with... Unhandled Exception: