Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SQL Server bacpac fails on local import in latest update (Online index operations can only be performed in Enterprise edition of SQL Server)

I have an SQL Azure database and connect to it in SQL Server Management Studio. I do Export Data Tier Application and then Import Data Tier Application for the .bacpac file to get it into my localdb. Or I use Tasks - Deploy Database.

Either way, it worked up until recently and now I get an error

Online index operations can only be performed in Enterprise edition of SQL Server

I am using SQL Server Management Studio versions below (from Help - About). Any ideas?

SQL Server Management Studio                    15.0.18369.0
SQL Server Management Objects (SMO)             16.100.46041.41
Microsoft Analysis Services Client Tools        15.0.19342.0
Microsoft Data Access Components (MDAC)         10.0.19041.1
Microsoft MSXML                                 3.0 6.0 
Microsoft .NET Framework                        4.0.30319.42000
Operating System                                10.0.19041
like image 956
Vince Avatar asked Jan 04 '21 21:01

Vince


People also ask

How do I import a Bacpac file to an existing database?

To import from a BACPAC file into a new single database using the Azure portal, open the appropriate server page and then, on the toolbar, select Import database. Select the storage account and the container for the BACPAC file and then select the BACPAC file from which to import.

What is Bacpac file in SQL Server?

A BACPAC file is a ZIP file with an extension of BACPAC containing the metadata and data from the database. A BACPAC file can be stored in Azure Blob storage or in local storage in an on-premises location and later imported back into Azure SQL Database, Azure SQL Managed Instance, or a SQL Server instance.

Can we restore Bacpac file in SQL Server?

You can not directly restore this type of file but have to follow a few steps to import it into your database with us. To do this you will need the latest SQL Server Management Studio (SSMS), a local instance of SQL Server, either Express or any full version, and your . bacpac file.

What is SQL Azure import BACPAC failures?

The error, SQL Azure Import Bacpac Failures may occur due to an invalid bacpac file. As part of our Server Management Services, we assist our customers with several such errors on a daily basis. Today, let us discuss how to troubleshoot SQL Azure Import Bacpac Failures.

Why is my BACPAC import not working?

When importing a bacpac, all applications that run against it should be disabled. Otherwise, this may create an issue where an import fails with the database present, but missing data. Make a list of all the applications that point to a server; if running into any issue during an import, either

How do I open a BACPAC file in SQL Server?

To start, open SQL Server Management Studio (SSMS) and connect to a local instance of SQL Server. Right-click on the instance name and select Import Data-tier Application. Simply click Next to go back the welcome screen of the import wizard. Click browse and locate the BACPAC file on your local computer. Click Next.

What is the import-BACPAC function in SQL Server?

The below function is an altered version of the Import-Bacpac function. It allows us to import multiple bacpacs by location and also allows us to pass in our own connection string, whether that is a local SQL Server environment or an Azure-SQL environment.


3 Answers

Among bug fixes in SSMS 18.9:

Fixed in issue where importing a bacpac into SQL Express may fail. See SQL Server user feedback.

This issue with SSMS 18.8 had been acknowledge by the product team, but was fixed:

I apologize for the inconvenience of this issue, we are working to include a fix in the next release of SSMS. In the meantime, installing SSMS 18.7.1 (https://learn.microsoft.com/sql/ssms/release-notes-ssms?view=sql-server-ver15#1871) will allow you to complete the bacpac import operations on SQL Server Express.

like image 82
dahlbyk Avatar answered Oct 24 '22 06:10

dahlbyk


If instead of using localdb you can upgrade to or use SQL Server 2019 Developer Edition, then you won't have any issues. Developer Edition is free and has the same features as Enterprise Edition. You can download Developer Edition from here and then update it with the latest cumulative update from here, after that try to import the bacpac to the Developer Edition instance.

like image 25
Alberto Morillo Avatar answered Oct 24 '22 08:10

Alberto Morillo


I just ran into this same exact problem again today. I exported our database from Azure into a BACPAC and was having trouble with SSMS loading it into SQL Express.

Just by pure luck, I found SSMS 18.9 was released today and appears to have fixed the issue in my case.

like image 1
Kyle Weishaupt Avatar answered Oct 24 '22 06:10

Kyle Weishaupt