All Downloads are FREE. Search and download functionalities are using the official Maven repository.

liquibase.sdk.vagrant.supplier.mssql.mssql.init.sql.vm Maven / Gradle / Ivy

There is a newer version: 3.6.2.5.inovus
Show newest version
USE master;
GO

CREATE LOGIN [${supplier.databaseUsername}] WITH PASSWORD = '${supplier.databasePassword}';
GO

CREATE LOGIN [${supplier.alternateUsername}] WITH PASSWORD = '${supplier.alternateUserPassword}';
GO


--primary database
CREATE DATABASE [${supplier.primaryCatalog}]
GO

USE ${supplier.primaryCatalog};
GO

CREATE USER ${supplier.databaseUsername} FOR LOGIN ${supplier.databaseUsername};
GO

EXEC sp_addrolemember 'db_owner', '${supplier.databaseUsername}';
GO

CREATE USER ${supplier.alternateUsername} FOR LOGIN ${supplier.alternateUsername};
GO

EXEC sp_addrolemember 'db_owner', '${supplier.alternateUsername}';
GO



--alternate database
CREATE DATABASE [${supplier.alternateCatalog}]
GO

USE ${supplier.alternateCatalog};
GO

CREATE USER ${supplier.databaseUsername} FOR LOGIN ${supplier.databaseUsername};
GO

EXEC sp_addrolemember 'db_owner', '${supplier.databaseUsername}';
GO

CREATE USER ${supplier.alternateUsername} FOR LOGIN ${supplier.alternateUsername};
GO

EXEC sp_addrolemember 'db_owner', '${supplier.alternateUsername}';
GO




© 2015 - 2024 Weber Informatics LLC | Privacy Policy