Guest User

Untitled

a guest
Jun 25th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. C:\>sqlcmd -S localhost -U sa -P 1234
  2.  
  3. 1> -- Set TriadWorksDb as the current database
  4. 2> USE TriadWorksDb;
  5. 3> GO
  6. Changed database context to 'TriadWorksDb'.
  7.  
  8. 1> -- Create a new server login name: rponte
  9. 2> CREATE LOGIN rponte WITH PASSWORD = 'TopSecret'
  10. 3> GO
  11.  
  12. 1> -- Create a new database user linked to the login name
  13. 2> CREATE USER rponte FOR LOGIN rponte;
  14. 3> GO
  15.  
  16. 1> -- Grant database ALTER permision to the user
  17. 2> GRANT ALTER To rponte;
  18. 3> GO
  19.  
  20. 1> -- Grant database CONTROL permision to the user
  21. 2> GRANT CONTROL To rponte;
  22. 3> GO
Add Comment
Please, Sign In to add comment