March 13, 2012 at 12:48 pm
Hi all,
I've got a problem right now that is making me want to pull hair out. Here's the situation, it has to do with logins.
Using Service Broker, on one database (receive side) the activation stored procedure is failing with error, the queue is specified to activate with OWNER permissions:
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.
I'm using SSMS 2008 R2 to connect to this 2005 instance, I went to Security->Users->right click on sa->Properties->User Mapping. When I scroll down to the database with the issue, it is the only DB with the User Mapping unchecked. All of the others (that work properly) have the user mapping checked to dbo/dbo for user/schema. The problem is, that it won't let me check the box. When I do it fails with the error:
Alter Failed for login 'sa'. Cannot set credential for principal 'sa'.
So, how do I setup this mapping?
March 13, 2012 at 1:36 pm
Well, I figured out the answer in my case. What happened is that somehow (I still don't know how) an sa user and schema were created in that database. Additionally the dbo role (user) did not have a login specified (should be sa in my case). When I removed the sa user and schema, all I had to do was run sp_changedbowner 'sa' and everything worked.
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply