MSSQLSERVER_15517
Topic Status: Some information in this topic is preview and subject to change in future releases. Preview information describes new features or changes to existing features in Microsoft SQL Server 2016 Community Technology Preview 2 (CTP2).
Details
Product Name |
SQL Server |
Event ID |
15517 |
Event Source |
MSSQLSERVER |
Component |
SQLEngine |
Symbolic Name |
SEC_CANNOTEXECUTEASUSER |
Message Text |
Cannot execute as the database principal because the principal "principal" does not exist, this type of principal cannot be impersonated, or you do not have permission. |
User Action
Use the name of an existing principal or get the IMPERSONATE permission on that principal.
15517 can also occur after performing an attach and restore of a database by someone other than the original database owner. To resolve this error, change the db_owner to a login on your server, by running the following command:
ALTER AUTHORIZATION ON DATABASE:: DBName TO [NewLogin]