I need to move a SQL 2008 R2 on-premis database to an Azure SQL cloud database. The database is to big to script out with data and Azure SQL cloud cannot restore a standard .bak file.

Trying to use Tasks --> Export data-tier application from this guide toghether with SSMS 2016 to create the .bacpac file that I will import to Azure SQL cloud. But I keep getting this errormessage: User [test_user] has an unresolved reference to login [test_user].

See below for complete message. Error

Why do I get this error? Maybe there is a better way to export / import a database from SQL 2008 to Azure SQL?

  • 1
    Check if you have the privileges to view definition's on logins. – Reaces Dec 13 '16 at 16:18
  • Thank you! Setting myself as a SysAdmin solved the problem. Should have thought about the permissions myself.. Do set your comment as an answer. – Andreas Dec 13 '16 at 16:56
  • I put it in a small answer. – Reaces Dec 13 '16 at 17:37

This error is usually caused by a lack of permissions.

As you are creating a bacpac file to transfer a database to azure, we can rule out permissions on the target server.
Which means you are most likely missing permission to read the login definitions on the source server.

You will need to grant your user VIEW DEFINITION ON LOGIN permissions, or add him to a role that has those permissions built in.

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.