Wednesday, June 22, 2016

SQL Server error Cannot execute as the database principal because the principal “dbo” does not exist

After restoring adventure works database, when trying to see database diagrams I got an error Cannot execute as the database principal because the principal “dbo” does not exist.

The solution is to reassign database owner using script
use [databasename] EXEC sp_changedbowner 'sa'

More Info

No comments:

c# httpclient The remote certificate is invalid according to the validation procedure: RemoteCertificateNameMismatch

 If we get this error while trying to get http reponse using HttpClient object, it could mean that certificate validation fails for the remo...