Migrate Logins, Users and Roles, select,execute,insert...etc permissions to other SQL Server

  • Hi All.

    Is there any way/ script which allows me to migrate the same permissions as we have in one server to other. Please help me . I have to migrate Logins, Users and Roles and permissions like selec, execute, update on specific objects.

    Thanks in advance

  • I have a couple of scripts that might help.

    I've attached the files - had to add .txt to the end to get them to upload.

    ScriptLoginDiffs.ps1 is a PowerShell script that compares two instances and generates a script to bring their logins in line, including SIDs, passwords, server roles, database roles (assuming a database of the same name exists on both instances). Call it with the following syntax:

    .\ScriptLoginDiffs.ps1 SERVER1\INST1 SERVER2\INST2

    All Login Permissions.sql is a TSQL script that scripts all login server permissions and roles, and database permissions and roles on an instance.

    Hope this helps.

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

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