Skip to content

Instantly share code, notes, and snippets.

@lpsm-dev
Last active December 27, 2021 22:26
Show Gist options
  • Save lpsm-dev/5bf0041a652230b51d46f73cac84d507 to your computer and use it in GitHub Desktop.
Save lpsm-dev/5bf0041a652230b51d46f73cac84d507 to your computer and use it in GitHub Desktop.
[Database] - Create User Read Only Policy in SQL Server 🌊
USE [database];
CREATE LOGIN [user] WITH PASSWORD = '123456';
CREATE USER [user] FOR LOGIN [user];
EXEC sp_addrolemember db_datareader, [user];
@lpsm-dev
Copy link
Author

Create User

Simples script to create user in SQL Server. Enjoy πŸ˜„!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment