CREATE TABLE [dbo].[SysuserGridState]
(
[SysuserGridStateID] [int] NOT NULL IDENTITY(1, 1),
[SysuserFID] [int] NOT NULL,
[GridName] [varchar] (32) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[GridState] [varbinary] (max) NULL,
[GridColumnNames] [varchar] (2048) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
ALTER TABLE [dbo].[SysuserGridState] ADD CONSTRAINT [PK_SysuserGridState] PRIMARY KEY CLUSTERED ([SysuserGridStateID]) ON [PRIMARY]
GO
CREATE NONCLUSTERED INDEX [IX_SysuserGridState_Sysuser_GridName] ON [dbo].[SysuserGridState] ([SysuserFID], [GridName]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[SysuserGridState] ADD CONSTRAINT [FK_SysuserGridState_Sysuser] FOREIGN KEY ([SysuserFID]) REFERENCES [dbo].[Sysuser] ([SysUserID])
GO
GRANT SELECT ON [dbo].[SysuserGridState] TO [MssExec]
GRANT INSERT ON [dbo].[SysuserGridState] TO [MssExec]
GRANT DELETE ON [dbo].[SysuserGridState] TO [MssExec]
GRANT UPDATE ON [dbo].[SysuserGridState] TO [MssExec]
GO