SQL Server principal “dbo” does not exist,

后端 未结 11 1058
醉话见心
醉话见心 2020-12-22 16:05

I am getting the following error

Cannot execute as the database principal because the principal \"dbo\" 
does not exist, this type of principal cannot be imp         


        
11条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-22 16:39

    I resolved this issue by setting database owner. My database did not have had any owner before this issue. Execute this command in your database to set owner to sysadmin account:

    use [YourDatabaseName] EXEC sp_changedbowner 'sa'
    

提交回复
热议问题