SDU Tools: Script User Defined Server Roles in SQL Server
As part of our free SDU Tools for developers and DBAs, we have many scripting functions. SQL Server allows you to create your own server roles, and generally, you should do this instead of using the fixed server roles, as it lets you allocate just the required permissions. To allow scripting these out, we’ve added a tool called ScriptUserDefinedServerRoles.
It’s a function and doesn’t require any parameters.
You can use our tools as a set or as a great example of how to write functions like these.
2019-12-11