We are doing the Sitecore 10.2 upgrade. We have exported and restored the Collection Shard0 and Shard1 into our local. We have successfully executed our upgrade script.

When we try to import the database again to Azure, we are getting the error. enter image description here


2 Answers 2


I also faced the same issue while I uploaded the DB backup on Azure BlobStorage and tried to restore it directly via Portal.

Connect the Azure SQL Server to your local SSMS. For that, you need to add your IP address to the Azure SQL Server Firewall rule.

See the article: https://docs.microsoft.com/en-us/azure/azure-sql/database/firewall-configure?view=azuresql

Once you are able to connect the Azure SQL server to the local SSMS then create the BACPAC file of the database instead of .bak file and try to restore the BACPAC file on Azure SQL Server.
See the blog post:

  1. How to create or export BACPAC file using SSMS?
  2. How To Import Or Restore BACPAC File Using SQL Server Management Studio

The easy way to do this is to make a copy of the Shard databases in the same Azure resource group or a different Azure resource group.

This approach is a lot quicker than exporting the database as a Copy of the database takes less than 10 minutes as against an Export of a few hours.

you can use the following command in Azure to copy the database

CREATE DATABASE [NewDatabaseName] AS COPY OF [ProdDatabaseServerName].[CurrentDatabaseName];

You can now update the database to 10.2 using the Sitecore scripts and rename the database using the following command

ALTER Database [UpdatedDatabase] MODIFY NAME = [ProdDatabaseName]

Or you can update connection strings to use the new database.

Please check my upgrade guide for 10.2 for more details


Hope this helps

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.