· 8 years ago · Jul 12, 2018, 09:18 AM
1IF db_name()<>'master' AND
2 NOT EXISTS (SELECT * FROM information_schema.tables
3 WHERE table_name = 'IRSystemSettings' AND table_type = 'BASE TABLE')
4BEGIN
5 PRINT 'Create table IRSystemSettings';
6 CREATE TABLE [dbo].[IRSystemSettings](
7
8 [ID] bigint IDENTITY(1, 1) NOT NULL , -- primary key
9 [Value] nvarchar(100) NOT NULL UNIQUE , -- text identifier value
10 [Description] nvarchar(max) NOT NULL , -- description on setting
11 [Type] tinyint NOT NULL , -- configuration identifier
12 [IsDeleted] bit NOT NULL , -- #####
13 [DeleteDateUTC] datetime NULL , -- #####
14 [ModificationDateUTC] datetime NULL , -- #####
15
16
17 CONSTRAINT PK_IRSystemSettings PRIMARY KEY CLUSTERED ([ID])
18 );
19END;
20GO
21--- end IRSystemSettings