SQL SERVER – Fix Error – Cannot execute as the database principal because the principal “dbo” does not exist

One of my clients recently sent me an email with the following error. The error was visible in the error log and was about the database principal.

Cannot execute as the database principal because the principal “dbo” does not exist, this type of principal cannot be impersonated, or you do not have permission.

It is very simple to fix the error. It happens because of the database owner is blank in the database properties for the file. Here is the screenshot of the database property.

SQL SERVER - Fix Error - Cannot execute as the database principal because the principal "dbo"  does not exist errorfix

If you change the owner to the database owner or SA, it will start working again. Well, the solution is that simple.

Here are six-part blog post series I have written based on my last 10 years of experience helping with the Comprehensive Database Performance Health Check. I strongly recommend you to read them as they walk you through my business model.

If you have any questions, you can always reach out to me on Twitter.

Reference: Pinal Dave (http://blog.SQLAuthority.com)

SQL Error Messages, , SQL Scripts, SQL Server, SQL Server Security
Previous Post
SQL SERVER – Converting Unix TimeStamp to DateTime
Next Post
SQL SERVER – Last Used Stored Procedure

Related Posts

8 Comments. Leave new

Leave a ReplyCancel reply

Exit mobile version