Share via

Error occured while restoring the database in Azure sql server

2022-05-17T08:42:56.437+00:00

I’m trying to restore the DB from the exported file and getting below error. Please check and assist as ap. Thanks

202638-image.png

Azure SQL Database

1 answer

Sort by: Most helpful
  1. Alberto Morillo 35,506 Reputation points MVP Volunteer Moderator
    2022-05-17T10:21:37.8+00:00

    Please make sure you are "restoring" (importing) the database with a different name as the source database from where the bacpac was created. Importing database cannot replace existing databases.

    In addition, as a workaround, Try using PowerShell instead of the portal.

    New-AzureRmSqlDatabaseImport –ResourceGroupName “sqlgroup” –ServerName “powershellserver” –DatabaseName “mypowershelldatabase” –StorageKeytype “StorageAccessKey” –StorageKey $primarykey -StorageUri $StorageUri –AdministratorLogin $credential.UserName –AdministratorLoginPassword $credential.Password –Edition Basic –ServiceObjectiveName B -DatabaseMaxSizeBytes 50000
    

    Finally, make sure the access tier of the bacpac on Azure Storage is type "Cool".

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.