Link to home
Start Free TrialLog in
Avatar of street9009
street9009Flag for United States of America

asked on

SQL Server 2005: Create the same User Role on New Database

Is it possible to export a user role from one MSSQL database and create the same role with same permissions on a new database?
Avatar of pssandhu
pssandhu
Flag of Canada image

Avatar of street9009

ASKER

Hmm. I kinda understand, but I'm not sure I know how to use it.
Here is another article from Microsoft explaining the same. I do not think there is a quick way to do this.

http://support.microsoft.com/kb/246133

P.
the above are good for logins, which is step#1 and needful before getting the users and user roles in (db_datareader etc)

http://www.sql-server-performance.com/articles/dba/object_permission_scripts_p1.aspx
gives you script to do the database roles.
I just need a script that will output what I need to create a custom user role on any database. I already have the proper queries to grant the users that role and revoke the others.
ASKER CERTIFIED SOLUTION
Avatar of anushahanna
anushahanna
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks