CREATE LOGIN [scu\SVCSPVisioUnattended] FROM WINDOWS
USE DW
go
CREATE USER [SVCSPVisioUnattended] FROM LOGIN [scu\SVCSPVisioUnattended]
EXEC sys.sp_addrolemember 'db_datareader', 'SVCSPVisioUnattended'
USE [CorporateDirectoryTest]
GO
CREATE USER [SVCSPVisioUnattended] FROM LOGIN [scu\SVCSPVisioUnattended]
EXEC sys.sp_addrolemember 'db_datareader', 'SVCSPVisioUnattended'
create login RestrictMyIO with password=N'RestrictMyIO', default_database = dbTest2, check_expiration=off,check_policy=off
use dbTest2
create user RestrictMyIO for login RestrictMyIO
alter role db_owner add member RestrictMyIO