I am attempting to backup and restore a database located in Azure SQL database via Azure blob storage. To do this I have run Export Data-Tier Application...
on the selected database and successfully stored it in a blob container as a BACPAC file. Now I am trying to do the reverse and Import Data-Tier Application...
to check the backup process functions correctly, however I receive the following error during the process:
Could not import package.
Error SQL72014: .Net SqlClient Data Provider: Msg 15063, Level 16, State 1, Line 1 The login already has an account under a different user name.
Error SQL72045: Script executation error. The executed script: CREATE USER [username] FOR LOGIN [username];
(Microsoft.SqlServer.Dac)
This results in the Importing database
, Importing package schema and data into database
and Updating database
operations failing, and the creation of an empty database.
I'm unsure where the login or creating a user becomes relevant in importing the database, do you know why this error is occuring?