I saw a login that was in the sysadmin role and shouldn't have been. When I went to the database access tab under properties for the login, each database had "dbo" in the user column. I couldn't change it so I removed the login and added him back. After being sure the login had only db_datareader rights, when I tried to save the new login I got an error "the login already has an account under a different user name". When I clicked ok I got an error "Cannot drop the database owner". I'm in a loop and can't get out of EM.
How do I fix it? Would using sp_changedbowner in QA to change the database owner to another login fix it?
yes, sp_changedbowner will transfer ownership from that account to another you specified
but if the account has created objects and in his ownership you need to issue sp_changeobjectowner too before you can drop his account from that database
SELECT so.name AS objectname, su.name AS ownername
FROM
sysobjects so
INNER JOIN sysusers su ON so.uid = su.uid
WHERE su.name = 'whatevertheusernameis'