Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Create New db User and copy old Users Permissions?

Author  Topic 

binici
Starting Member

5 Posts

Posted - 2010-03-25 : 16:26:01
Hi all! Haven't been here in a while. I have a simple question: I created a new User for a new DB I restored "blahNew" and would like the old User "blahOld" permissions (set on object tables ans sp's) to be simply carried over for "blahNew" user, rather than manually going through the objects and setting them, is this possible?

Using a script or system sp? I couldn't find a thorough answer for the inquiry I have.

Thanks!

DBA in the making
Aged Yak Warrior

638 Posts

Posted - 2010-03-25 : 21:21:21
Is this something you plan on doing a lot? If so, you should create a roll with the necessary permissions, and add both users to the role.

I don't know of an easy was to script user permissions.

There are 10 types of people in the world, those that understand binary, and those that don't.
Go to Top of Page

binici
Starting Member

5 Posts

Posted - 2010-03-25 : 21:35:54
I just change a database to reflect my website name and updated a few objects, so I created a new Login for the DB and a new User. I guess I will just manually apply the permission for the user.

Thanks!
Go to Top of Page
   

- Advertisement -