Cannot export databse to BACPAC format for import into Azure Database

I am trying to import a database into my Azure SQL Database.  I found some instructions on how to do this by exporting the database to BACPAC format.  I tried this with a small test database and got it to work without problem.  However I am now trying to export my main database to BACPAC format and when I attempt to do so, I get the following error:

------------------------

Validation of the schema model for data package failed.

Error SQL71564: Error validating element [mydatabase]: The element [mydatabase] has been orphaned from it's login and cannot be deployed.

(Microsoft.SqlServer.Dac)

-----------------------

Can anyone explain what is going on here and how I might fix it?

Thanks.


  • Edited by John Gaby Monday, December 09, 2013 5:30 PM
December 9th, 2013 8:28pm

I had the same issue - it means that there is a user in your database that does not have a login - http://www.fileformat.info/tip/microsoft/sql_orphan_user.htm

I fixed it by creating a new user and login

Free Windows Admin Tool Kit Click here and download it now
December 11th, 2013 5:00am

I had the same problem. Deleting the user at the DB level (which was not at the server level) led to the next 71564 error which was much more descriptive (missing primary key). One the PK was applied, the bacpac went right into Azure. Thanks.
December 11th, 2013 9:46pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics