Articles about European Sharepoint Hosting Service
SharePoint 2013 Hosting UK – HostForLIFE.eu :: How to Add User To SharePoint Database Admin Using PowerShell Script?
This course will help you learn the basics or refresh your knowledge and then provide a deeper understanding of advanced features of SharePoint 2013 from beginners to advanced users.
SharePoint 2013 is a collaboration environment that organizations of all sizes can use to increase the efficiency of business processes.
PowerShell is essentially the same, but with a lot more power. You can type your commands there and see the results just like before.
However, the benefit is that you can add your own “Shells” or set commands to enable the person using it to do more.
Steps
Use the Add-SPShellAdmin cmdlet to add a user to the SharePoint_Shell_Access role.
Syntax
1 |
Add-SPShellAdmin [-UserName] <String> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-database <SPDatabasePipeBind>] [-WhatIf [<SwitchParameter>]] |
Specifies the GUID of the database or the Database object that includes the SharePoint_Shell_Access role to which you want to add the user.
The Database parameter is not specified, the configuration database is used by default.
The farm configuration database is always included- if you specify another database.
Example
This will add a new user to the SharePoint_Shell_Access role in the farm configuration database.
1 |
Add-SPShellAdmin -UserName SPDEV\gowtham |
This will add a new user to the SharePoint_Shell_Access role in both, the specified content database and the configuration database, by passing a database GUID to the cmdlet.
1 |
Add-SPShellAdmin -UserName SPDEV\gowtham -database 4hty1d844-3d45-4501-8dd1-98f960359fa6 |
Conclusion
Was my blog helpful? If yes, please let me know and if not, please explain what was confusing or missing. I’ll use your feedback to double-check the facts, add info and update this blog.
Print article | This entry was posted by Peter on October 12, 2017 at 7:42 am, and is filed under European SharePoint 2013 Hosting. Follow any responses to this post through RSS 2.0. You can leave a response or trackback from your own site. |