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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Simple scripting question

Status
Not open for further replies.

SBendBuckeye

Programmer
May 22, 2002
2,166
US
Hello all,

We are running SqlServer 2005. For my current project, there is a group defined to which we need to Grant Execute permission for all select stored procs. I have been manually adding the group by right clicking the stored proc and then choosing Properties, Permissions, etc.

I'm thinking there has to be a way to script this and make it faster and less error prone if I forget one.

A. Can I script this process to pass in the StoredProc name and then have it add the group for me?

B. Can I write a script like A that only adds the group if it does not already exist?

C. Can I write a script that returns this information for every stored proc in the database?

Sorry if these are really obvious questions. Thanks in advance for any ideas and/or suggestions!
 
This should be asked in this forum forum1555. DTS no longer exists in 2005.

Hope this helps,

Alex

Ignorance of certain subjects is a great part of wisdom
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top