Migrate SQL Logins to another SQL Server

There are often situations where you need to copy/move/migrate/transfer SQL logins from one SQL server to another. For example, if you've restored a database to a new SQL server (and will do so frequently in the future, such as in a log shipping environment) and you want to use the same SQL login credentials to login to the new server as you used on the previous server.

In order to properly move/copy/migrate/transfer a SQL login (and maintain the same SID), you'll need to perform the steps from the following procedure:

1. copy script from method 3 on this page: http://support.microsoft.com/kb/918992

2. run that on the original server (from SQL management studio)

3. run the following command on the original server: EXEC sp_help_revlogin

4. copy the output (or just a portion of it) and run it on the new server (from sql management studio)