July 21, 2006 at 1:32 am
When we went to change a 'sa' password recently we got the error 21776. BOL and Microsoft say theat this error was caused by a restore to the server where the database owner on the source server does not exit on the destination server. The owner on the the source server was the same as the owner on the destination server but, when we looked again at the owner on the destination server, it had changed to 'sa'.
We then ran sp_changedbowner to change to the correct owner but got the result that 'The proposed new database owner is already a user in the database'. We then disconnected and reconnect to the destination server. The 'sa' password had changed but the owner is still 'sa'.
The database on the destination server is a test database to which recent changes have been made by the software supplier, one of which is that certain users in the database have now become system and security administrators on the server and db_owners of the database. I have recently posted threads on this change of permissions as we thought these software changes would give us difficulties.
We could try detaching and re-attaching the database but don't know if that we give us even more difficulties. Has anyone had experience of this or advice to offer?
Madame Artois
July 21, 2006 at 1:17 pm
The user that owns the database doesn't exist on your test system. You can create that user and restore or detach reattach and sql should remap the user that now exist on the system with the user that is listed at the database level.
Wes
July 24, 2006 at 1:44 am
Actually the user has existed on both the test and live server for over two years with exactly the same permissions and ownership.
That's why we are confused; this user was the first created on both servers.
Madame Artois
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply