Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Granting permissions

Status
Not open for further replies.

wbodger

Programmer
Apr 23, 2007
769
US
So, I have to every now and then create a new database, create some general tables, views and sprocs, all of which I have created scripts to do, and then there are the permissions. There are three of four SQL Server logins that I have to assign as Users on the new database, give them roles and then assign them Execute rights on the sprocs. I guess I have the script to assign execute on the sprocs, so I am looking for help on a script to assign logins to a db and then to assign them roles in that database. So, I have the SQL Server Login tblCreator and I want to assign that login to the new DB dbLetsGoHere and I want him to have the roles db_datareader, db_datawriter and db_owner. Help?

wb
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top