SDU Tools: Script Server Role members in SQL Server

SDU Tools: Script Server Role members in SQL Server

In our free SDU Tools for developers and DBAs, there’s another useful scripting tool. It scripts out the logins that are members of server roles. It’s called ScriptServerRoleMembers.

One key advantage of having these scripting procedures and functions is that you incorporate them into other applications, and programmatically perform the scripting if you need to.

But if you just want to create a script, that works too.

By default, it lists permissions for all logins, but you can also provide a list of the logins that you’re interested in, as a comma-delimited list, to the @LoginsToScript parameter.

You can see an example of both in the main image above, and you can watch it in action here:

https://youtu.be/pszTHe2PhVQ

To become an SDU Insider and to get our free tools and eBooks, please just visit here:

http://sdutools.sqldownunder.com

2019-01-16