Re: Same Server and DB - Copy users and roles
From: Ray Higdon (sqlhigdon_at_nospam.yahoo.com)
Date: 01/12/04
- Previous message: Dan Guzman: "Re: only 1 row from a join"
- In reply to: Kevin Evans: "Re: Same Server and DB - Copy users and roles"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Sun, 11 Jan 2004 19:12:10 -0500
This page may help:
http://support.microsoft.com/default.aspx?scid=kb;en-us;246133
-- Ray Higdon MCSE, MCDBA, CCNA --- "Kevin Evans" <kevin@convenientcomputing.com> wrote in message news:eJUZvmH2DHA.1396@TK2MSFTNGP10.phx.gbl... > Thanks Dejan > > The script generator worked great with one exception. The permissions set on > the roles were not transferred along with the role to the new database. Is > there some additional setting on permission I need to complete this? > > I'm using SQL2K and I'm logged in as the administrator > > Thanks Again > Kevin > > "Dejan Sarka" <dejan_please_reply_to_newsgroups.sarka@avtenta.si> wrote in > message news:eP$NdMF2DHA.3416@tk2msftngp13.phx.gbl... > > > I have an application that requires a different database for each year > of > > > data. I have the same users for all years at a given time. Logins are > not > > a > > > problem because they are on the same server but how do I automate the > user > > > and role updates made in the current years database to all other > > databases. > > > > You can create scripts (in fact, you could change the permissions with a > > script in the first place) with EM or DMO and implement them in other > > databases. Check the "Documenting and Scripting Databases" topic in Books > > OnLine. > > > > > I have hundreds of users and tables to set various securities on and > have > > to > > > replicate the permission changes across all dbs. In fact, after a number > > of > > > years I need to change users to read only on most tables. > > > > You can generate a script using a cursor and dynamic SQL to automate the > > permissions management. Instead of a cursor, you can help yourself with > the > > sp_MSforeachtable system SP. Check the article at > > http://www.databasejournal.com/features/mssql/article.php/1490661. > > > > -- > > Dejan Sarka, SQL Server MVP > > Please reply only to the newsgroups. > > > > > >
- Previous message: Dan Guzman: "Re: only 1 row from a join"
- In reply to: Kevin Evans: "Re: Same Server and DB - Copy users and roles"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|