Saturday, March 19, 2016

sql server - Move SQL 2008 database to Azure



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?


Answer




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.


No comments:

Post a Comment

linux - How to SSH to ec2 instance in VPC private subnet via NAT server

I have created a VPC in aws with a public subnet and a private subnet. The private subnet does not have direct access to external network. S...