Data Management

How do I... Transfer logins from one SQL Server 2005 instance to another SQL Server 2005 instance?

By Steven Warren

This gallery is also available as a TechRepublic blog post and download.

In my last How do I..., I discussed how to restore a SQL Server to a new server. After the article published, I had some questions on the best way to move SQL Server logins from one SQL Server 2005 instance to another SQL Server 2005 instance.

I want to preface that you can move logins from one SQL Server to another SQL Server in many different ways. In my experience, I have found that this is the easiest way to move logins from one SQL Server to another SQL Server while keep existing passwords.

We will begin by downloading a script called Sp_Help_RevLogin.

Note: If you are transferring logins from SQL Server 2000 to SQL Server 2005, download this script.

Next, navigate to Start | All Programs | Microsoft SQL Server 2005 | SQL Server Management Studio. Simply highlight and copy the script from the link provided and paste into SQL Server Management Studio as shown.

Note: When you first open SQL Server Management Studio, you must click New Query, and select the Master database prior to pasting the script and clicking Execute.

Free Newsletters, In your Inbox