CREATE TABLE [dbo].[SysuserSetting]
(
[SysuserSettingID] [int] NOT NULL IDENTITY(1, 1),
[SysuserFID] [int] NOT NULL,
[SettingName] [varchar] (32) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[IntValue] [int] NULL,
[StringValue] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[LongStringValue] [varchar] (4096) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[BoolValue] [bit] NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SysuserSetting] ADD CONSTRAINT [PK_SysuserSetting] PRIMARY KEY CLUSTERED ([SysuserSettingID]) ON [PRIMARY]
GO
CREATE UNIQUE NONCLUSTERED INDEX [IX_SysuserSetting_Sysuser_Name] ON [dbo].[SysuserSetting] ([SysuserFID], [SettingName]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SysuserSetting] ADD CONSTRAINT [FK_SysuserSetting_Sysuser] FOREIGN KEY ([SysuserFID]) REFERENCES [dbo].[Sysuser] ([SysUserID])
GO
GRANT SELECT ON [dbo].[SysuserSetting] TO [MssExec]
GRANT INSERT ON [dbo].[SysuserSetting] TO [MssExec]
GRANT DELETE ON [dbo].[SysuserSetting] TO [MssExec]
GRANT UPDATE ON [dbo].[SysuserSetting] TO [MssExec]
GO