Jan
31
2013

How to transfer logins and passwords between instances of SQL Server 2008

How to transfer logins and passwords between instances of SQL Server 2008How to transfer logins and passwords between instances of SQL Server 2008

1. On server A, start SQL Server Management Studio, and then connect to the instance of SQL Server from which you moved the database.

2. Open a new Query Editor window, and then run the following script.

3. Note This script creates two stored procedures in the master database. The procedures are named sp_hexadecimal and sp_help_revlogin.

4. Run the following statement:

 

 

The output script that the sp_help_revlogin stored procedure generates is the login script. This login script creates the logins that have the original Security Identifier (SID) and the original password.

5. On server B, start SQL Server Management Studio, and then connect to the instance of SQL Server to which you moved the database.

Important Before you go to step 5, review the information in the “Remarks” section on How to transfer logins and passwords between instances of SQL Server

6. Open a new Query Editor window, and then run the output script that is generated in step 3.

 

Download PDF

Related Posts

About the Author: Nitin G

Indian born, trekker, biker, photographer, lover of monsoons. I've been working full time with SQL Server since year 2005 and blogs to post the content aquired during my research on new topics or fixing issues faced by me as a DBA while working in different kind of projects, hope some of my posts may helps others in SQLDBA community. Everything you read on my blog is my own personal opinion and any code is provided "AS-IS" with no warranties!

Leave a comment

Subscribe to this blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 174 other subscribers

Translate this blog!

EnglishFrenchGermanItalianPortugueseRussianSpanish

Calender

May 2019
M T W T F S S
« Nov    
 12345
6789101112
13141516171819
20212223242526
2728293031  

View Post by Categories

%d bloggers like this: