Orphaned dbo User...

  • I've gotten myself into a situation where I've restored a backup of a database on one server over to another server and restored it there. Once restored, the 'dbo' user in the database is orphaned, and I can't seem to figure out how to reassociate it with the standard "sa" login on the new server... Does anyone have any suggestions...? Is there a better way to copy a database from one server to another...? Thanks...

  • It is expected, and normal, that 'dbo' user is orphaned.

     

    Try: sp_changedbowner 'sa'

    and then do sp_changedbowner 'domain\useraccount'  --the real owner.

    If the owner's login does not exist on the new server, you need to add the login and then run:

    EXEC sp_change_users_login 'Update_One', 'Mary', 'NewMary'

     

    mom

     

  • Thanks...!

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply