RE: moving/copying database

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance

From: John Bandettini (JohnBandettini_at_discussions.microsoft.com)
Date: 02/14/05


Date: Mon, 14 Feb 2005 06:23:08 -0800

Jason

Here are links to some articles that should help you resolve your problem.

http://www.support.microsoft.com/?id=246133 How To Transfer Logins and
Passwords Between SQL Servers
http://www.support.microsoft.com/?id=298897 Mapping Logins & SIDs after a
Restore
http://www.dbmaint.com/SyncSqlLogins.asp Utility to map logins to users
http://www.support.microsoft.com/?id=168001 User Logon and/or Permission
Errors After Restoring Dump
http://www.support.microsoft.com/?id=240872 How to Resolve Permission Issues
When a Database Is Moved Between SQL Servers

Hope this helps

John

"Jason" wrote:

> Hello,
>
> Does somebody knows a complete solution for resolving the following issues
> when moving or copying a database to another sql server?
>
> - when attaching the moved database, i have orphan users. So i use the
> sp_help_revlogin to re-create those users. This works ok.
>
> - when attaching a database which has roles and permissions defined, the
> only thing that gets fixed are the logins.
>
> I hope somebody has faced this problem before and can give me a solution.
>
> Thnx
>
>
>



Relevant Pages

  • Re: Error 15022: The specified user name is already aliased.
    ... Issues When a Database Is Moved Between SQL Servers ... > permit role it shows that the user has a dbo role. ...
    (microsoft.public.sqlserver.security)
  • Re: logins fail after re attaching Database
    ... http://www.support.microsoft.com/?id=168001 User Logon and/or Permission ... Issues When a Database Is Moved Between SQL Servers ...
    (microsoft.public.sqlserver.security)
  • Re: Preserve Logins and Users
    ... How To Transfer Logins and Passwords Between SQL Servers ... Q240872 How to Resolve Permission Issues When a Database Is Moved Between ...
    (microsoft.public.sqlserver.security)
  • Re: Logging in irrespective of database access
    ... Try connecting using Query Analyzer with one of the problem logins and run ... the following in the context of your demodata and accounts databases: ... This will return the security context used to access the database. ... SQL Server MVP ...
    (microsoft.public.sqlserver.server)
  • Re: Logging in irrespective of database access
    ... Try connecting using Query Analyzer with one of the problem logins and run ... the following in the context of your demodata and accounts databases: ... This will return the security context used to access the database. ... SQL Server MVP ...
    (microsoft.public.sqlserver.programming)