Error while importing bacpak in Sql Server 2012 - sql-server

I'm getting this error while importing bacpac file from windows azure
TITLE: Microsoft SQL Server Management Studio
------------------------------
Count not load schema model from package. (Microsoft.SqlServer.Dac)
------------------------------
ADDITIONAL INFORMATION:
Internal Error. The internal target platform type SqlAzureDatabaseSchemaProvider
does not support schema file version '2.5'.
Most of the help online suggests upgrading SSDT, but I have the latest version of SSDT for VS2012 already installed

Update - with a number of new features including Query Store, it's now best to use the SQL Server Management Studio Preview to import. In some cases this will be necessary given updated features in the bacpac file. You can install this from its download page. On that download page choose "Download SQL Server Management Studio Preview" to install.
Original Answer
The best solution is to install SQL Server Management Studio 2014 from the Express download page. On that download page choose "MgmtStudio 32BIT\SQLManagementStudio_x86_ENU.exe" installer when clicking the download link. SSMS 2014 contains a more recent DacFx version that supports version 2.5 and has full support for SQL Server 2005-2014 dbs, along with Azure DBs.
A few notes on DacFx / SqlPackage:
Installing the latest SSDT won't fix the issue since SSDT no longer installs Dac DLLs in a shared location. Instead it installs them under the Visual Studio install dir (C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\Extensions\Microsoft\SQLDB\DAC\120).
To update DacFx binaries used in SSMS to the latest version you must install the DacFramework.msi directly. You can download the latest version for 2014 here (this will update the location used by SSMS 2014), or if you have to use SSMS 2012 the last version compatible with that is found here.
SqlPackage.exe does support bacpacs. You need to use the Import/Export actionsfor bacpacs rather than the Extract/Publish actions used for dacpacs.

It will not directly restore. As you already install "SQL Server Data Tools", please check links.
http://social.technet.microsoft.com/Forums/en-US/66a4dfeb-c626-45eb-af3c-00e7e5996203/bacpac-file-import-from-windows-azure-fails?forum=ssdt
Azure SQL Database Bacpac Local Restore
http://social.msdn.microsoft.com/forums/windowsazure/en-us/36035d1e-fda8-4388-99c4-ba2ff7c5a5e1/new-sql-azure-bacpac-format-not-working-with-sql-2012
http://saransh77.wordpress.com/2013/05/02/part-1-how-to-manually-backup-azure-sql-database-and-import-in-on-premise-sql-server/

It looks to me that something has recently changed Azure side to break even using SQL Server 2014 Management Studio. I had to install the Cumulative Update 5 onto SQL Server 2014 Management Studio to get this working again. Looks like Cumulative Update 6 is out so you could also try that.

I've updated my SQL Server 2012 with SP2 and then I could actually Import BACPAC files from Azure. You can try that.

I understand that this has been there for a while but those who have still this problem, this happens because of having an older version of Microsoft® SQL Server® Data-Tier Application Framework.
Installing the latest version solved the problem.
At the time I am writing this is the latest and I was using an older which was incompatible with the bacpac file I was trying to import.
http://www.microsoft.com/en-us/download/details.aspx?id=46898

Related

The Script Task Uses Version 15.0 that is not supported in the release of integration services

My team is planning to move from SQL Server 2014 to 2016. Currently, SSIS package is created in VS 2013 and deployed on SQL Server 2014. For testing i tried to deploy the package in SSMS 17.3 (Integration services 13.0). The package is successfully deployed but when i try to validate the package, the get the following error:
After reading some solutions on the internet, I deployed the package from the following path:
%ProgramFiles%\Microsoft SQL Server\130\DTS\Binn
The package was successfully validated (without modifying ispac file). As per my understanding, the script task is created with VSTA major version 15 in VS 2017. I tried to open the solution in VS 2015 and rebuilt the solution with SQL server 2017 as target server. Before deploying the package on SSMS 17.3, I made sure that the dtsx file contains 15 VSTA major version.
After verifying, i deployed the package on SSMS 17.3 which is using the following path:
%ProgramFiles%\Microsoft SQL Server\140\DTS\Binn
I validated the package but i got the same error. As per my understanding, if i build the solution by selecting SQL server 2017 as target version, it should be successfully validated. How can i resolve this issue if i want to use SSMS 17.3 for deployment?
In my case the Target Server Version was set to 2017. I updated it to 2016 and it worked.
After searching for a while on this issue, it looks like this is a common issue of SSMS 17.x you must install 16.x versions to avoid this error or deploy with SQL Server 2016 deployment tools (Microsoft SQL Server\130\DTS\Binn) as you mentioned:
For more information, read the discussions below, they contains very helpful
SSMS 17.3 and VS 2015 deployment issue
Difference between .ispac and SSDT deploy

Unpacking and building SQL Server 2014 project with VS2012 sqlpackage.exe

I've been trying to test whether a project (DB, SSIS, SSAS) built on SQL Server 2014 will be compatible with SQL Server 2012. I've got a .dproj packed in dacpac format and when I try to run this from cmd:
sqlpackage.exe /Action:Script /SourceFile:"Project.dacpac" /TargetDatabaseName:DBName /TargetServerName:"DBName /p:BlockOnPossibleDataLoss=false /p:RegisterDataTierApplication=true /p:BlockWhenDriftDetected=false /OutputPath:Logs\Output.sql
I get a following error:
*** Could not deploy package. Internal Error. The database platform service with type Microsoft.Data.Tools.Sch
ema.Sql.Sql120DatabaseSchemaProvider is not valid. You must make sure
the servic e is loaded, or you must provide the full type name of a
valid database platform service.
I created a VM on Azure with SQL Server installed. Apart from that I installed Data Tools for VS 2012. I'm guessing that it might be compatibility problem, but maybe there's a workaround this without changing DT to a higher version? Any patch that could be applied?
You can install a more recent dacfx (sqlpackage) or you can copy the DAC folder from a more recent version to the deploy machine and use that instance of sqlpackage.exe to deploy.
You can also set the properties in the project itself to target SQL Server 2012 and it will validate that the T-SQL is correct for SQL Server 2012 and let you deploy to it.
There were lots of fixes between sqlpackage 2012 and 2014 so I would move them onto a newer version of sqlpackage even if you still target a SQL Server 2012 box.
This is only for dacpacs, not sure about the other projects.

No SQL Server Data Tools in VS 2013 ultimate installed

I have no SQL Server Data Tool in Visual Studio 2013.
SSDT should be included in VS2013? Source
How can I install them?
I tried to install BI for VS 2013 but still don't have any SQL functions in VS.
Make sure Microsoft SQL Server Data Tools is checked when you install VS.
SQL tools like schema comparison are in SQL menu. SQL menu is not visible till any database project OR .scmp file OR file where its context is available is open.
For more details, refer:
http://pranavwithyou.wordpress.com/2013/09/20/schema-data-comparison-of-two-databases-with-visual-studio/
http://channel9.msdn.com/Events/Visual-Studio/Launch-2013/VS108
Update
Got this link on MSDN:
http://msdn.microsoft.com/en-us/data/hh297027
Download latest VS2013 Update 2 through extension update or by link http://www.visualstudio.com/downloads/download-visual-studio-vs
For SSDT-BI for VS 2013 install:
http://www.microsoft.com/en-us/download/details.aspx?id=42313
after installation restart Visual studio.
Lets hope, it should work then.
I don't have SQL menu, however I found it in Tools -> SQL Server

SSDT Not Working In Visual Studio 2010 SP1

I'm running Visual Studio 2010 SP1 Premium on Windows 7, and am trying to create SQL Server Reporting Services (SSRS) Reports. I've downloaded the new SQL Server Data Tools (SSDT) from http://msdn.microsoft.com/en-us/data/hh297027 and installed/restarted. If I go into VS Help->About, I can see "Microsoft SQL Server Data Tools 10.3.20225.0" in the list of installed products. However, SSDT doesn't seem to be showing up in the "New Project" window, and if I try to open existing SSRS 2005 reports projects (created in BIDS/VS 2005) it says "'Reports.rptproj' cannot be opened because its project type (.rptproj) is not supported by this version of the application. To open it, please use a version that supports this type of project".
Am I incorrect in my impression that VS/SSDT does not require SQL Server being installed? Is there some other software, package, or step that I'm missing in installing SSDT?
For SQL Server 2012 SSRS, the functionality of BIDS is REPLACED by SSDT. If you are working with SQL Server 2008 R2 (or earlier) SSRS, then you'll want to use BIDS from that version of SQL Server.
When you install SSDT, it includes templates for BI projects (i.e. SSAS, SSIS, SSRS). SSDT can be installed as a stand-alone application, or, if you have VS2010 SP1 on your machine, then SSDT will install inside of VS2010.
For the OLTP (including offline) database projects, there is NO template. Rather there is a new View named 'SQL Server Object Explorer'. For more about the latter, see my blog post.
The new project type is found under Other Languages->SQL Server-> SQL Sever Database Project.
Do not confuse that with the old to be deprecated projects under Database->SQL Server->Advanced
The BIDS part of SSDT is sort of a separate install. (although they've tried making it seem like one install.) See this on information about why one or the other might not be installed:
http://www.jamesserra.com/archive/2012/04/ssdt-installation-confusion/

Visual Studio and SQL Server - correct installation sequence?

I am rebuilding my development machine. This issue is not new to me, but I don't remember the solution.
I started with SQL 2008 Developer, then VS 2008 Pro, then the SQL SP1, then VS SP1. The result is that I cannot open SSIS projects (see the error below). What is the correct order so that I can avoid the installation of SQL Server Express and still have all the features working?
---------------------------
Microsoft Visual Studio
---------------------------
Package Load Failure
Package 'DataWarehouse VSIntegration layer' has failed to load properly ( GUID =
{4A0C6509-BF90-43DA-ABEE-0ABA3A8527F1} ). Please contact package vendor for
assistance. Application restart is recommended, due to possible environment
corruption. Would you like to disable loading this package in the future? You
may use 'devenv /resetskippkgs' to re-enable package loading.
---------------------------
Yes No
---------------------------
You should install SQL 2008 Developer first, this will rule out the need for VS installing SQL which comes with it. Or you could do like others suggested and choose custom VS installation.
My favorite way is this:
SQL 2008 Developer
Visual Studio Professional 2008
Run Windows Updates
Install Resharper :-)
Install RedGate SQL ToolBelt
But it seems that to get some features to work the proper order is:
Visual Studio Professional 2008 (with SQL Unchecked)
SQL 2008 Developer
Run Windows Updates
Install Resharper/Redgate Tools
Resharper and Redgate in my opinion are far the best tools for developing in C#/SQL.
It turns out I was missing 2 important pieces of information in my question that make this installation such a pain:
I was installing the 64 bit version of SQL Server
I was installing to a non-standard location (i.e. the D: drive, because C: is an SSD with not all
that much space)
This was not successful. Here is what I ended up doing in my first (second, and third) attempt:
Install VS 2008 Professional on D:
Install VS 2008 SP 1
Install SQL Server 2008 Developer Edition (instance and shared components on D:)
Install SQL Server SP 1
Apparently VS 2008 Pro does not require a database. I am not sure why I remembered that it does. While the Visual Studio installation was eventless, I encountered the following errors during the SQL Server installation:
The INSTANCESHAREDWOWDIR command line value was not specified.
I was able to resolve that be starting setup from the command line (thanks to this MSDN forum post):
setup.exe /INSTALLSHAREDWOWDIR="D:\Program Files(x86)\Microsoft SQL
Server" /INSTALLSHAREDDIR="D:\Program Files\Microsoft SQL Server"
/ACTION=install
Then towards the end of the installation, I got this error:
Upgrade Failed due to the following Error.The error code is :-2147467259.Message:Unspecified error
There is no solution, but a workaround, described in this post on connect.microsoft.com. It consists of copying a VS config file around before and after the installation, and re-running the installer just for BIDS (which is the one component that failed).
The SQL Server SP1 installation ran without issue. VS Studio, when trying to load a solution with an SSIS project, still threw the error that I posted in my original question.
I had ignored this error that popped up towards the end of the BIDS installation:
Microsoft Visual Studio Tools for Applications 2.0
Cannot find one or more components. Please reinstall the application.
However, there was no error in the install log and it completed "successfully", so I thought it would be ok to ignore the error.
It seems that my configuration is not possible (but I know with certainty that I had the 2005 versions of VS and SQL Server on a D: drive).
I uninstalled everything once again, manually deleted whatever folders were left, and reinstalled on the C: drive, including the SQL Server shared components. I put the instance folder on the D:.
Install VS 2008 Professional on C:
Install VS 2008 SP 1
Install SQL Server 2008 Developer Edition (instance on D:, shared components on C:)
Install SQL Server SP 1
This time everything installed and I can open my SSIS project.
If you are trying to install SQL-2008 and you also have visual studio 2008 installed with service pack one (SP1) and get the error
A previous release of Microsoft Visual Studio 2008 is installed on
this computer. Upgrade Microsoft Visual Studio 2008 to the SP1 before
installing SQL Server 2008”
Then welcome to the Microsoft beta testing program even if you purchased the faulty software.
With XP the most common solution seem to be renaming the registry key
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\DevDiv\VS\Servicing\9.0
and replacing 9.0 with 9.0Old. However this does not solve the problem if you are using windows 7 and the only solution I managed to find that worked was to uninstall VS2008 and all the components and to then install SQL-2008 and finally reinstall VS2008.
Install Visual Studio Professional 2008.
Install SQL 2008 Developer
Apply SQL SP1
Apply VS SP1
Then all should be good.

Resources